Skip to content

emka.web.id

Menu
  • Home
  • Indeks Artikel
  • Tutorial
  • Tentang Kami
Menu

Belajar WordPress: Memfasilitasi Contributor untuk Upload File

Posted on February 16, 2012 by Syauqi Wiryahasana
Contributer, adalah role di WordPress yang hanya dapat memberikan kontribusi tulisan saja. Silakan taruh snippet berikut di file function .php themes anda... [sourcecode language="php"] 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'); } [/sourcecode] Selamat mencoba!
Seedbacklink

Recent Posts

TENTANG EMKA.WEB>ID

EMKA.WEB.ID adalah blog seputar teknologi informasi, edukasi dan ke-NU-an yang hadir sejak tahun 2011. Kontak: kontak@emka.web.id.

©2024 emka.web.id Proudly powered by wpStatically