Advertisement
Guest User

Untitled

a guest
May 5th, 2016
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.31 KB | None | 0 0
  1. include_once('advanced-custom-fields/acf.php');
  2. include_once('acf-options-page/acf-options-page.php');
  3. include_once('acf-repeater/acf-repeater.php');
  4. define( 'ACF_LITE', true );
  5.  
  6. if(function_exists("register_field_group"))
  7. {
  8.  
  9. register_field_group(array (
  10. 'id' => 'acf_options',
  11. 'title' => 'Options',
  12. 'fields' => array (
  13. array (
  14. 'key' => 'field_525d1b6d49043',
  15. 'label' => 'lable',
  16. 'name' => 'homepage',
  17. 'type' => 'repeater',
  18. 'instructions' => 'Select which categories you want to display on the homepage.',
  19. 'sub_fields' => array (
  20. array (
  21. 'key' => 'field_525d1b8a49044',
  22. 'label' => 'Category',
  23. 'name' => 'firsttext',
  24. 'type' => 'text',
  25. 'column_width' => '',
  26. 'field_type' => 'text',
  27. 'return_format' => 'id',
  28. ),
  29. array (
  30. 'key' => 'field_525d2473de72c',
  31. 'label' => 'Number of Posts',
  32. 'name' => 'number-of-posts',
  33. 'type' => 'text',
  34. 'column_width' => '',
  35. 'default_value' => 4,
  36. 'placeholder' => '',
  37. 'prepend' => '',
  38. 'append' => '',
  39. 'min' => 2,
  40. 'max' => '',
  41. 'step' => 2,
  42. ),
  43. ),
  44. 'row_min' => 1,
  45. 'row_limit' => 1,
  46. 'layout' => 'row',
  47. 'button_label' => 'Add a category',
  48. ),
  49.  
  50.  
  51. ),
  52. 'location' => array (
  53. array (
  54. array (
  55. 'param' => 'options_page',
  56. 'operator' => '==',
  57. 'value' => 'acf-options',
  58. 'order_no' => 0,
  59. 'group_no' => 0,
  60. ),
  61. ),
  62. ),
  63. 'options' => array (
  64. 'position' => 'normal',
  65. 'layout' => 'no_box',
  66. 'hide_on_screen' => array (
  67. ),
  68. ),
  69. 'menu_order' => 0,
  70. ));
  71. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement