bbp_admin_get_settings_fields

Get all of the settings fields.

Description

bbp_admin_get_settings_fields(); 

Usage

  1. if ( !function_exists( 'bbp_admin_get_settings_fields' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'bbpress/includes/admin/settings.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = bbp_admin_get_settings_fields(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/includes/admin/settings.php  
  1. function bbp_admin_get_settings_fields() { 
  2. return (array) apply_filters( 'bbp_admin_get_settings_fields', array( 
  3.  
  4. /** User Section ******************************************************/ 
  5.  
  6. 'bbp_settings_users' => array( 
  7.  
  8. // Edit lock setting 
  9. '_bbp_edit_lock' => array( 
  10. 'title' => __( 'Disallow editing after', bbpress ),  
  11. 'sanitize_callback' => 'intval',  
  12. 'args' => array() 
  13. ),  
  14.  
  15. // Throttle setting 
  16. '_bbp_throttle_time' => array( 
  17. 'title' => __( 'Throttle posting every', bbpress ),  
  18. 'sanitize_callback' => 'intval',  
  19. 'args' => array() 
  20. ),  
  21.  
  22. // Allow anonymous posting setting 
  23. '_bbp_allow_anonymous' => array( 
  24. 'title' => __( 'Anonymous posting', bbpress ),  
  25. 'sanitize_callback' => 'intval',  
  26. 'args' => array() 
  27. ),  
  28.  
  29. // Allow global access (on multisite) 
  30. '_bbp_allow_global_access' => array( 
  31. 'title' => __( 'Auto role', bbpress ),  
  32. 'sanitize_callback' => 'intval',  
  33. 'args' => array() 
  34. ),  
  35.  
  36. // Allow global access (on multisite) 
  37. '_bbp_default_role' => array( 
  38. 'sanitize_callback' => 'sanitize_text_field',  
  39. 'args' => array() 
  40. ),  
  41.  
  42. /** Features Section **************************************************/ 
  43.  
  44. 'bbp_settings_features' => array( 
  45.  
  46. // Allow topic and reply revisions 
  47. '_bbp_allow_revisions' => array( 
  48. 'title' => __( 'Revisions', bbpress ),  
  49. 'sanitize_callback' => 'intval',  
  50. 'args' => array() 
  51. ),  
  52.  
  53. // Allow favorites setting 
  54. '_bbp_enable_favorites' => array( 
  55. 'title' => __( 'Favorites', bbpress ),  
  56. 'sanitize_callback' => 'intval',  
  57. 'args' => array() 
  58. ),  
  59.  
  60. // Allow subscriptions setting 
  61. '_bbp_enable_subscriptions' => array( 
  62. 'title' => __( 'Subscriptions', bbpress ),  
  63. 'sanitize_callback' => 'intval',  
  64. 'args' => array() 
  65. ),  
  66.  
  67. // Allow topic tags 
  68. '_bbp_allow_topic_tags' => array( 
  69. 'title' => __( 'Topic tags', bbpress ),  
  70. 'sanitize_callback' => 'intval',  
  71. 'args' => array() 
  72. ),  
  73.  
  74. // Allow topic tags 
  75. '_bbp_allow_search' => array( 
  76. 'title' => __( 'Search', bbpress ),  
  77. 'sanitize_callback' => 'intval',  
  78. 'args' => array() 
  79. ),  
  80.  
  81. // Allow fancy editor setting 
  82. '_bbp_use_wp_editor' => array( 
  83. 'title' => __( 'Post Formatting', bbpress ),  
  84. 'args' => array(),  
  85. 'sanitize_callback' => 'intval' 
  86. ),  
  87.  
  88. // Allow auto embedding setting 
  89. '_bbp_use_autoembed' => array( 
  90. 'title' => __( 'Auto-embed links', bbpress ),  
  91. 'sanitize_callback' => 'intval',  
  92. 'args' => array() 
  93. ),  
  94.  
  95. // Set reply threading level 
  96. '_bbp_thread_replies_depth' => array( 
  97. 'title' => __( 'Reply Threading', bbpress ),  
  98. 'sanitize_callback' => 'intval',  
  99. 'args' => array() 
  100. ),  
  101.  
  102. // Allow threaded replies 
  103. '_bbp_allow_threaded_replies' => array( 
  104. 'sanitize_callback' => 'intval',  
  105. 'args' => array() 
  106. ),  
  107.  
  108. /** Theme Packages ****************************************************/ 
  109.  
  110. 'bbp_settings_theme_compat' => array( 
  111.  
  112. // Theme package setting 
  113. '_bbp_theme_package_id' => array( 
  114. 'title' => __( 'Current Package', bbpress ),  
  115. 'sanitize_callback' => 'esc_sql',  
  116. 'args' => array() 
  117. ),  
  118.  
  119. /** Per Page Section **************************************************/ 
  120.  
  121. 'bbp_settings_per_page' => array( 
  122.  
  123. // Replies per page setting 
  124. '_bbp_topics_per_page' => array( 
  125. 'title' => __( 'Topics', bbpress ),  
  126. 'sanitize_callback' => 'intval',  
  127. 'args' => array() 
  128. ),  
  129.  
  130. // Replies per page setting 
  131. '_bbp_replies_per_page' => array( 
  132. 'title' => __( 'Replies', bbpress ),  
  133. 'sanitize_callback' => 'intval',  
  134. 'args' => array() 
  135. ),  
  136.  
  137. /** Per RSS Page Section **********************************************/ 
  138.  
  139. 'bbp_settings_per_rss_page' => array( 
  140.  
  141. // Replies per page setting 
  142. '_bbp_topics_per_rss_page' => array( 
  143. 'title' => __( 'Topics', bbpress ),  
  144. 'sanitize_callback' => 'intval',  
  145. 'args' => array() 
  146. ),  
  147.  
  148. // Replies per page setting 
  149. '_bbp_replies_per_rss_page' => array( 
  150. 'title' => __( 'Replies', bbpress ),  
  151. 'sanitize_callback' => 'intval',  
  152. 'args' => array() 
  153. ),  
  154.  
  155. /** Front Slugs *******************************************************/ 
  156.  
  157. 'bbp_settings_root_slugs' => array( 
  158.  
  159. // Root slug setting 
  160. '_bbp_root_slug' => array( 
  161. 'title' => __( 'Forum Root', bbpress ),  
  162. 'sanitize_callback' => 'bbp_sanitize_slug',  
  163. 'args' => array() 
  164. ),  
  165.  
  166. // Include root setting 
  167. '_bbp_include_root' => array( 
  168. 'title' => __( 'Forum Prefix', bbpress ),  
  169. 'sanitize_callback' => 'intval',  
  170. 'args' => array() 
  171. ),  
  172.  
  173. // What to show on Forum Root 
  174. '_bbp_show_on_root' => array( 
  175. 'title' => __( 'Forum root should show', bbpress ),  
  176. 'sanitize_callback' => 'sanitize_text_field',  
  177. 'args' => array() 
  178. ),  
  179. ),  
  180.  
  181. /** Single Slugs ******************************************************/ 
  182.  
  183. 'bbp_settings_single_slugs' => array( 
  184.  
  185. // Forum slug setting 
  186. '_bbp_forum_slug' => array( 
  187. 'title' => __( 'Forum', bbpress ),  
  188. 'sanitize_callback' => 'bbp_sanitize_slug',  
  189. 'args' => array() 
  190. ),  
  191.  
  192. // Topic slug setting 
  193. '_bbp_topic_slug' => array( 
  194. 'title' => __( 'Topic', bbpress ),  
  195. 'sanitize_callback' => 'bbp_sanitize_slug',  
  196. 'args' => array() 
  197. ),  
  198.  
  199. // Topic tag slug setting 
  200. '_bbp_topic_tag_slug' => array( 
  201. 'title' => __( 'Topic Tag', bbpress ),  
  202. 'sanitize_callback' => 'bbp_sanitize_slug',  
  203. 'args' => array() 
  204. ),  
  205.  
  206. // View slug setting 
  207. '_bbp_view_slug' => array( 
  208. 'title' => __( 'Topic View', bbpress ),  
  209. 'sanitize_callback' => 'bbp_sanitize_slug',  
  210. 'args' => array() 
  211. ),  
  212.  
  213. // Reply slug setting 
  214. '_bbp_reply_slug' => array( 
  215. 'title' => __( 'Reply', bbpress ),  
  216. 'sanitize_callback' => 'bbp_sanitize_slug',  
  217. 'args' => array() 
  218. ),  
  219.  
  220. // Search slug setting 
  221. '_bbp_search_slug' => array( 
  222. 'title' => __( 'Search', bbpress ),  
  223. 'sanitize_callback' => 'bbp_sanitize_slug',  
  224. 'args' => array() 
  225. ),  
  226.  
  227. /** User Slugs ********************************************************/ 
  228.  
  229. 'bbp_settings_user_slugs' => array( 
  230.  
  231. // User slug setting 
  232. '_bbp_user_slug' => array( 
  233. 'title' => __( 'User Base', bbpress ),  
  234. 'sanitize_callback' => 'bbp_sanitize_slug',  
  235. 'args' => array() 
  236. ),  
  237.  
  238. // Topics slug setting 
  239. '_bbp_topic_archive_slug' => array( 
  240. 'title' => __( 'Topics Started', bbpress ),  
  241. 'sanitize_callback' => 'bbp_sanitize_slug',  
  242. 'args' => array() 
  243. ),  
  244.  
  245. // Replies slug setting 
  246. '_bbp_reply_archive_slug' => array( 
  247. 'title' => __( 'Replies Created', bbpress ),  
  248. 'sanitize_callback' => 'bbp_sanitize_slug',  
  249. 'args' => array() 
  250. ),  
  251.  
  252. // Favorites slug setting 
  253. '_bbp_user_favs_slug' => array( 
  254. 'title' => __( 'Favorite Topics', bbpress ),  
  255. 'sanitize_callback' => 'bbp_sanitize_slug',  
  256. 'args' => array() 
  257. ),  
  258.  
  259. // Subscriptions slug setting 
  260. '_bbp_user_subs_slug' => array( 
  261. 'title' => __( 'Topic Subscriptions', bbpress ),  
  262. 'sanitize_callback' => 'bbp_sanitize_slug',  
  263. 'args' => array() 
  264. ),  
  265.  
  266. /** BuddyPress ********************************************************/ 
  267.  
  268. 'bbp_settings_buddypress' => array( 
  269.  
  270. // Are group forums enabled? 
  271. '_bbp_enable_group_forums' => array( 
  272. 'title' => __( 'Enable Group Forums', bbpress ),  
  273. 'sanitize_callback' => 'intval',  
  274. 'args' => array() 
  275. ),  
  276.  
  277. // Group forums parent forum ID 
  278. '_bbp_group_forums_root_id' => array( 
  279. 'title' => __( 'Group Forums Parent', bbpress ),  
  280. 'sanitize_callback' => 'intval',  
  281. 'args' => array() 
  282. ),  
  283.  
  284. /** Akismet ***********************************************************/ 
  285.  
  286. 'bbp_settings_akismet' => array( 
  287.  
  288. // Should we use Akismet 
  289. '_bbp_enable_akismet' => array( 
  290. 'title' => __( 'Use Akismet', bbpress ),  
  291. 'sanitize_callback' => 'intval',  
  292. 'args' => array() 
  293. ) );