pustakakoran

Mengganti Tulisan TAGS

Mar 18th, 2018
86
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. TAGS menjadi KEYWORDS
  2. pastekan kode berikut di functions.php pada theme:
  3.  
  4. function change_tax_object_label() {
  5. global $wp_taxonomies;
  6. $labels = &$wp_taxonomies['post_tag']->labels;
  7. $labels->name = __('Keywords', 'framework');
  8. $labels->singular_name = __('Keywords', 'framework');
  9. $labels->search_items = __('Search Keywords', 'framework');
  10. $labels->all_items = __('Keywords', 'framework');
  11. $labels->separate_items_with_commas = __('Separate Keywords with commas', 'framework');
  12. $labels->choose_from_most_used = __('Choose from the most used Keywords', 'framework');
  13. $labels->popular_items = __('Popular Keywords', 'framework');
  14. $labels->edit_item = __('Edit Keyword Name', 'framework');
  15. $labels->view_item = __('View Keyword Name', 'framework');
  16. $labels->update_item = __('Update Keyword Name', 'framework');
  17. $labels->add_new_item = __('Add Your Keyword Name', 'framework');
  18. $labels->new_item_name = __('Your New Keywords Name', 'framework');
  19. }
  20. add_action( 'init', 'change_tax_object_label' );
  21.  
  22. ========================
  23. TAGS menjadi PENERBIT
  24.  
  25. function change_tax_object_label() {
  26. global $wp_taxonomies;
  27. $labels = &$wp_taxonomies['post_tag']->labels;
  28. $labels->name = __('Penerbit', 'framework');
  29. $labels->singular_name = __('Penerbit', 'framework');
  30. $labels->search_items = __('Cari Penerbit', 'framework');
  31. $labels->all_items = __('Penerbit', 'framework');
  32. $labels->separate_items_with_commas = __('Pisahkan dengan Koma', 'framework');
  33. $labels->choose_from_most_used = __('Pilih Penerbit yang Sudah Ada', 'framework');
  34. $labels->popular_items = __('Penerbit Populer', 'framework');
  35. $labels->edit_item = __('Edit Nama Penerbit', 'framework');
  36. $labels->view_item = __('Lihat Nama Penerbit', 'framework');
  37. $labels->update_item = __('Perbaiki Nama Penerbit', 'framework');
  38. $labels->add_new_item = __('Tambah Nama Penerbit', 'framework');
  39. $labels->new_item_name = __('Nama Penerbit yang Baru', 'framework');
  40. }
  41. add_action( 'init', 'change_tax_object_label' );
RAW Paste Data