Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

Upload/Insert Bar Not Visible for Contributor WordPress

  • SOLVED

<strong>I have someone on my site as a Contributor, but the Upload/Insert Bar is not showing when they add a new post.</strong> This is the bar that I'm referring to - [[LINK href="http://cl.ly/3V2o2t362A1j3I1O0T3j"]]http://cl.ly/3V2o2t362A1j3I1O0T3j[[/LINK]].
<strong>
Is there a way to add this for a Contributor?</strong>

Thanks for your help!

Answers (1)

2011-07-19

Romel Apuya answers:

yes.. try this..


//allow contributor to add photos
if ( current_user_can('contributor') && !current_user_can('upload_files') ) {
add_action('admin_init', 'allow_contributor_uploads');
function allow_contributor_uploads() {
$contributor = get_role('contributor');
$contributor->add_cap('upload_files');
}
}


Spencer Barfuss comments:

You got it! Thanks!