Skip to:
Content

bbPress.org

Changeset 4933


Ignore:
Timestamp:
05/20/2013 08:21:30 PM (13 years ago)
Author:
johnjamesjacoby
Message:

Move user base setting into new Users section. Tweak some verbiage to be more succinct. See #1500.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/admin/settings.php

    r4932 r4933  
    234234            // Root slug setting
    235235            '_bbp_root_slug' => array(
    236                 'title'             => __( 'Forums base', 'bbpress' ),
     236                'title'             => __( 'Forum Root', 'bbpress' ),
    237237                'callback'          => 'bbp_admin_setting_callback_root_slug',
    238238                'sanitize_callback' => 'esc_sql',
     
    263263            // Forum slug setting
    264264            '_bbp_forum_slug' => array(
    265                 'title'             => __( 'Forum slug', 'bbpress' ),
     265                'title'             => __( 'Forum', 'bbpress' ),
    266266                'callback'          => 'bbp_admin_setting_callback_forum_slug',
    267267                'sanitize_callback' => 'sanitize_title',
     
    271271            // Topic slug setting
    272272            '_bbp_topic_slug' => array(
    273                 'title'             => __( 'Topic slug', 'bbpress' ),
     273                'title'             => __( 'Topic', 'bbpress' ),
    274274                'callback'          => 'bbp_admin_setting_callback_topic_slug',
    275275                'sanitize_callback' => 'sanitize_title',
     
    279279            // Topic tag slug setting
    280280            '_bbp_topic_tag_slug' => array(
    281                 'title'             => __( 'Topic tag slug', 'bbpress' ),
     281                'title'             => __( 'Topic Tag', 'bbpress' ),
    282282                'callback'          => 'bbp_admin_setting_callback_topic_tag_slug',
    283283                'sanitize_callback' => 'sanitize_title',
     
    285285            ),
    286286
     287            // View slug setting
     288            '_bbp_view_slug' => array(
     289                'title'             => __( 'Topic View', 'bbpress' ),
     290                'callback'          => 'bbp_admin_setting_callback_view_slug',
     291                'sanitize_callback' => 'sanitize_title',
     292                'args'              => array()
     293            ),
     294
    287295            // Reply slug setting
    288296            '_bbp_reply_slug' => array(
    289                 'title'             => __( 'Reply slug', 'bbpress' ),
     297                'title'             => __( 'Reply', 'bbpress' ),
    290298                'callback'          => 'bbp_admin_setting_callback_reply_slug',
    291299                'sanitize_callback' => 'sanitize_title',
     
    293301            ),
    294302
     303            // Search slug setting
     304            '_bbp_search_slug' => array(
     305                'title'             => __( 'Search', 'bbpress' ),
     306                'callback'          => 'bbp_admin_setting_callback_search_slug',
     307                'sanitize_callback' => 'sanitize_title',
     308                'args'              => array()
     309            )
     310        ),
     311
     312        /** User Slugs ********************************************************/
     313
     314        'bbp_settings_user_slugs' => array(
     315
    295316            // User slug setting
    296317            '_bbp_user_slug' => array(
    297                 'title'             => __( 'User slug', 'bbpress' ),
     318                'title'             => __( 'User Base', 'bbpress' ),
    298319                'callback'          => 'bbp_admin_setting_callback_user_slug',
    299320                'sanitize_callback' => 'sanitize_title',
     
    301322            ),
    302323
    303             // View slug setting
    304             '_bbp_view_slug' => array(
    305                 'title'             => __( 'Topic view slug', 'bbpress' ),
    306                 'callback'          => 'bbp_admin_setting_callback_view_slug',
    307                 'sanitize_callback' => 'sanitize_title',
    308                 'args'              => array()
    309             ),
    310 
    311             // Search slug setting
    312             '_bbp_search_slug' => array(
    313                 'title'             => __( 'Search slug', 'bbpress' ),
    314                 'callback'          => 'bbp_admin_setting_callback_search_slug',
    315                 'sanitize_callback' => 'sanitize_title',
    316                 'args'              => array()
    317             )
    318         ),
    319 
    320         /** User Slugs ********************************************************/
    321 
    322         'bbp_settings_user_slugs' => array(
    323 
    324324            // Topics slug setting
    325325            '_bbp_topic_archive_slug' => array(
    326                 'title'             => __( 'User Topics', 'bbpress' ),
     326                'title'             => __( 'Topics Started', 'bbpress' ),
    327327                'callback'          => 'bbp_admin_setting_callback_topic_archive_slug',
    328328                'sanitize_callback' => 'esc_sql',
     
    332332            // Replies slug setting
    333333            '_bbp_reply_archive_slug' => array(
    334                 'title'             => __( 'User Replies', 'bbpress' ),
     334                'title'             => __( 'Replies Created', 'bbpress' ),
    335335                'callback'          => 'bbp_admin_setting_callback_reply_archive_slug',
    336336                'sanitize_callback' => 'esc_sql',
     
    340340            // Favorites slug setting
    341341            '_bbp_user_favs_slug' => array(
    342                 'title'             => __( 'User Favorite Topics', 'bbpress' ),
     342                'title'             => __( 'Favorite Topics', 'bbpress' ),
    343343                'callback'          => 'bbp_admin_setting_callback_user_favs_slug',
    344344                'sanitize_callback' => 'esc_sql',
     
    348348            // Subscriptions slug setting
    349349            '_bbp_user_subs_slug' => array(
    350                 'title'             => __( 'User Subscribed Topics', 'bbpress' ),
     350                'title'             => __( 'Topic Subscriptions', 'bbpress' ),
    351351                'callback'          => 'bbp_admin_setting_callback_user_subs_slug',
    352352                'sanitize_callback' => 'esc_sql',
     
    761761        flush_rewrite_rules(); ?>
    762762
    763     <p><?php _e( 'Custom root slug to prefix your forums section with. This can be partnered with a WordPress page and Shortcode to allow more flexibility.', 'bbpress' ); ?></p>
     763    <p><?php _e( 'Customize your Forums root. Partner with a WordPress Page and use Shortcodes for more flexibility.', 'bbpress' ); ?></p>
    764764
    765765<?php
     
    844844?>
    845845
    846     <p><?php _e( 'Custom slugs to customize your forums user profiles.', 'bbpress' ); ?></p>
    847 
    848 <?php
     846    <p><?php _e( 'Customize your user profile slugs.', 'bbpress' ); ?></p>
     847
     848<?php
     849}
     850
     851/**
     852 * User slug setting field
     853 *
     854 * @since bbPress (r2786)
     855 *
     856 * @uses bbp_form_option() To output the option value
     857 */
     858function bbp_admin_setting_callback_user_slug() {
     859?>
     860
     861    <input name="_bbp_user_slug" type="text" id="_bbp_user_slug" class="regular-text code" value="<?php bbp_form_option( '_bbp_user_slug', 'users', true ); ?>"<?php bbp_maybe_admin_setting_disabled( '_bbp_user_slug' ); ?> />
     862
     863<?php
     864    // Slug Check
     865    bbp_form_slug_conflict_check( '_bbp_user_slug', 'users' );
    849866}
    850867
     
    927944?>
    928945
    929     <p><?php printf( __( 'Custom slugs for single forums, topics, replies, tags, users, and views here. If you change these, existing permalinks will also change.', 'bbpress' ), get_admin_url( null, 'options-permalink.php' ) ); ?></p>
     946    <p><?php printf( __( 'Custom slugs for single forums, topics, replies, tags, views, and search.', 'bbpress' ), get_admin_url( null, 'options-permalink.php' ) ); ?></p>
    930947
    931948<?php
     
    9991016    // Slug Check
    10001017    bbp_form_slug_conflict_check( '_bbp_topic_tag_slug', 'topic-tag' );
    1001 }
    1002 
    1003 /** Other Slugs ***************************************************************/
    1004 
    1005 /**
    1006  * User slug setting field
    1007  *
    1008  * @since bbPress (r2786)
    1009  *
    1010  * @uses bbp_form_option() To output the option value
    1011  */
    1012 function bbp_admin_setting_callback_user_slug() {
    1013 ?>
    1014 
    1015     <input name="_bbp_user_slug" type="text" id="_bbp_user_slug" class="regular-text code" value="<?php bbp_form_option( '_bbp_user_slug', 'users', true ); ?>"<?php bbp_maybe_admin_setting_disabled( '_bbp_user_slug' ); ?> />
    1016 
    1017 <?php
    1018     // Slug Check
    1019     bbp_form_slug_conflict_check( '_bbp_user_slug', 'users' );
    10201018}
    10211019
Note: See TracChangeset for help on using the changeset viewer.