| @@ -34,15 +34,15 @@ | ||
| 34 | 34 | |
| 35 | 35 | <?php // sets up the tabs ?> |
| 36 | 36 | <h2 class="nav-tab-wrapper"> |
| 37 | 37 | |
| 38 | - <a href="?page=bbp-private-group-settings&tab=forum_visibility_settings" class="nav-tab <?php echo $active_tab == 'forum_visibility_settings' ? 'nav-tab-active' : ''; ?>"><?php _e('Forum Visibility settings' , 'bbp-private-groups' ) ; ?></a> | |
| 39 | - <a href="?page=bbp-private-group-settings&tab=general_settings" class="nav-tab <?php echo $active_tab == 'general_settings' ? 'nav-tab-active' : ''; ?>"><?php _e('General Settings' , 'bbp-private-groups' ) ; ?></a> | |
| 40 | - <a href="?page=bbp-private-group-settings&tab=group_name_settings" class="nav-tab <?php echo $active_tab == 'group_name_settings' ? 'nav-tab-active' : ''; ?>"><?php _e('Group Name Settings' , 'bbp-private-groups' ) ; ?></a> | |
| 41 | - <a href="?page=bbp-private-group-settings&tab=help" class="nav-tab <?php echo $active_tab == 'help' ? 'nav-tab-active' : ''; ?>"><?php _e('Help' , 'bbp-private-groups' ) ; ?></a> | |
| 42 | - <a href="?page=bbp-private-group-settings&tab=management_information" class="nav-tab <?php echo $active_tab == 'Management_information' ? 'nav-tab-active' : ''; ?>"><?php _e('Management Information' , 'bbp-private-groups' ) ; ?></a> | |
| 43 | - <a href="?page=bbp-private-group-settings&tab=user_management" class="nav-tab <?php echo $active_tab == 'user_management' ? 'nav-tab-active' : ''; ?>"><?php _e('User Management' , 'bbp-private-groups' ) ; ?></a> | |
| 44 | - <a href="?page=bbp-private-group-settings&tab=role_assignment" class="nav-tab <?php echo $active_tab == 'role_assignment' ? 'nav-tab-active' : ''; ?>"><?php _e('Assign groups to roles' , 'bbp-private-groups' ) ; ?></a></h2> | |
| 38 | + <a href="?page=bbp-private-group-settings&tab=forum_visibility_settings" class="nav-tab <?php echo $active_tab == 'forum_visibility_settings' ? 'nav-tab-active' : ''; ?>">Forum Visibility settings</a> | |
| 39 | + <a href="?page=bbp-private-group-settings&tab=general_settings" class="nav-tab <?php echo $active_tab == 'general_settings' ? 'nav-tab-active' : ''; ?>">General Settings</a> | |
| 40 | + <a href="?page=bbp-private-group-settings&tab=group_name_settings" class="nav-tab <?php echo $active_tab == 'group_name_settings' ? 'nav-tab-active' : ''; ?>">Group Name Settings</a> | |
| 41 | + <a href="?page=bbp-private-group-settings&tab=help" class="nav-tab <?php echo $active_tab == 'help' ? 'nav-tab-active' : ''; ?>">Help</a> | |
| 42 | + <a href="?page=bbp-private-group-settings&tab=management_information" class="nav-tab <?php echo $active_tab == 'Management_information' ? 'nav-tab-active' : ''; ?>">Management Information</a> | |
| 43 | + <a href="?page=bbp-private-group-settings&tab=user_management" class="nav-tab <?php echo $active_tab == 'user_management' ? 'nav-tab-active' : ''; ?>">User Management</a> | |
| 44 | + <a href="?page=bbp-private-group-settings&tab=role_assignment" class="nav-tab <?php echo $active_tab == 'role_assignment' ? 'nav-tab-active' : ''; ?>">Assign groups to roles</a></h2> | |
| 45 | 45 | <table class="form-table"> |
| 46 | 46 | <tr> |
| 47 | 47 | |
| 48 | 48 | <td> |
| @@ -52,9 +52,9 @@ | ||
| 52 | 52 | <input type="image" src="https://www.paypalobjects.com/en_US/GB/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal – The safer, easier way to pay online."> |
| 53 | 53 | <img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1"> |
| 54 | 54 | </form> |
| 55 | 55 | </td><td> |
| 56 | -<?php _e("If you find this plugin useful, please consider donating just a couple of dollars to help me develop and maintain it. You support will be appreciated", 'bbp-private-groups'); ?> | |
| 56 | +<?php _e("If you find this plugin useful, please consider donating just a couple of dollars to help me develop and maintain it. You support will be appreciated", 'bbp-last-post'); ?> | |
| 57 | 57 | |
| 58 | 58 | |
| 59 | 59 | </td> |
| 60 | 60 | </tr> |
| @@ -72,9 +72,9 @@ | ||
| 72 | 72 | <!-------------------------------Forum visibility ----------------------------------------> |
| 73 | 73 | |
| 74 | 74 | <tr valign="top"> |
| 75 | 75 | <th><h3><?php _e('Forum Visibility', 'bbp-private-groups'); ?></h3></th> |
| 76 | - <td><p><?php _e('By default only users with access to a forum will see the forum titles in the indexes. However you may want everyone to see that a forum exists (ie see the title) but not be able to access topics and replies within this. In this case, set the forum visibility below. If you want only logged in users to see these forums exist, then also set the forum to private within the dashboard>forums settings', 'bbp-private-groups') ?> <b> <?php _e ('See help tab for more information' , 'bbp-private-groups') ; ?></b></p></td> | |
| 76 | + <td><p><?php _e('By default only users with access to a forum will see the forum titles in the indexes. However you may want everyone to see that a forum exists (ie see the title) but not be able to access topics and replies within this. In this case, set the forum visibility below. If you want only logged in users to see these forums exist, then also set the forum to private within the dashboard>forums settings', 'bbp-private-groups') ?> <b> See help tab for more information</b></p></td> | |
| 77 | 77 | </tr> |
| 78 | 78 | |
| 79 | 79 | <!-- checkbox to activate --> |
| 80 | 80 | <tr valign="top"> |
| @@ -102,9 +102,9 @@ | ||
| 102 | 102 | <tr valign="top"> |
| 103 | 103 | <th><?php _e('URL of redirect page for NON-LOGGED-IN', 'bbp-private-groups'); ?></th> |
| 104 | 104 | <td> |
| 105 | 105 | <input id="rpg_settingsf[redirect_page2]" class="large-text" name="rpg_settingsf[redirect_page2]" type="text" value="<?php echo isset( $rpg_settingsf['redirect_page2'] ) ? esc_html( $rpg_settingsf['redirect_page2'] ) : '';?>" /><br/> |
| 106 | - <label class="description" for="rpg_settingsf[redirect_page]"><?php _e( 'Enter the full url (permalink) of the page to redirect users without access to eg http://www.mysite.com/sign-up. This can be the same as the LOGGED-IN page, just giving the opportunity to have different pages if you want them ! If you leave this blank, users will be sent to the Wordpress login page', 'bbp-private-groups' ); ?></label><br/> | |
| 106 | + <label class="description" for="rpg_settingsf[redirect_page]"><?php _e( 'Enter the full url (permalink) of the page to redirect users without access to eg http://www.mysite.com/sign-up. This can be the same as the LOGGED-IN page, just giving the opportunity to have different pages if you want them ! If you leave this blank, users will be sent to the wordpress login page', 'bbp-private-groups' ); ?></label><br/> | |
| 107 | 107 | </td> |
| 108 | 108 | </tr> |
| 109 | 109 | |
| 110 | 110 | <!-------------------------------Freshness settings ----------------------------------------> |
| @@ -221,10 +221,9 @@ | ||
| 221 | 221 | |
| 222 | 222 | <table class="form-table"> |
| 223 | 223 | |
| 224 | 224 | <tr valign="top"> |
| 225 | - <th colspan="2"><p> | |
| 226 | - <?php _e('This section allows you to set up groups. Enter a Description for each group eg gamers, teachers, group1 etc.' , 'bbp-private-groups' ) ; ?></p></th> | |
| 225 | + <th colspan="2"><p> This section allows you to set up groups. Enter a Description for each group eg gamers, teachers, group1 etc.</p></th> | |
| 227 | 226 | </tr> |
| 228 | 227 | <?php |
| 229 | 228 | $count=count ($rpg_groups) ; |
| 230 | 229 | if ($count==1) $count=2 ; |
| @@ -229,15 +228,14 @@ | ||
| 229 | 228 | $count=count ($rpg_groups) ; |
| 230 | 229 | if ($count==1) $count=2 ; |
| 231 | 230 | for ($i = 0 ; $i < $count ; ++$i) { |
| 232 | 231 | $g=$i+1 ; |
| 233 | - $display=__( 'Group', 'bbp-private-groups' ).$g ; | |
| 234 | 232 | $name="group".$g ; |
| 235 | 233 | $item="rpg_groups[".$name."]" ; |
| 236 | 234 | ?> |
| 237 | 235 | <!------------------------- Group ---------------------------------------------> |
| 238 | 236 | <tr valign="top"> |
| 239 | - <th><?php echo $display ?></th> | |
| 237 | + <th><?php echo $name ?></th> | |
| 240 | 238 | <td> |
| 241 | 239 | <?php echo '<input id="'.$item.'" class="large-text" name="'.$item.'" type="text" value="'.esc_html( $rpg_groups[$name] ).'"<br>' ; |
| 242 | 240 | ?> |
| 243 | 241 | </td> |
| @@ -283,19 +281,18 @@ | ||
| 283 | 281 | <?php |
| 284 | 282 | $count=count ($rpg_groups) ; |
| 285 | 283 | for ($i = 0 ; $i < $count ; ++$i) { |
| 286 | 284 | $g=$i+1 ; |
| 287 | - $display=__( 'Group', 'bbp-private-groups' ).$g ; | |
| 288 | 285 | $name="group".$g ; |
| 289 | 286 | $item="rpg_groups[".$name."]" ; |
| 290 | 287 | ?> |
| 291 | 288 | <!------------------------- Group ---------------------------------------------> |
| 292 | 289 | <tr valign="top"> |
| 293 | - <th><?php echo $display ?></th> | |
| 290 | + <th><?php echo $name ?></th> | |
| 294 | 291 | <td> |
| 295 | - <?php _e('Group name :', 'bbp-private-groups') ; ?> | |
| 292 | + Group name : | |
| 296 | 293 | <?php echo esc_html( $rpg_groups[$name] ).'<br>' ; ?> |
| 297 | - <?php _e('No. users in this group : ' , 'bbp-private-groups') ; ?> | |
| 294 | + No. users in this group : | |
| 298 | 295 | <?php |
| 299 | 296 | global $wpdb; |
| 300 | 297 | $users=$wpdb->get_col("select ID from $wpdb->users") ; |
| 301 | 298 | $countu=0 ; |
| @@ -310,9 +307,9 @@ | ||
| 310 | 307 | echo $countu ; |
| 311 | 308 | ?> |
| 312 | 309 | |
| 313 | 310 | |
| 314 | - <br><?php _e('Forums in this group :' , 'bbp-private-groups') ; ?> | |
| 311 | + <br>Forums in this group : | |
| 315 | 312 | <?php global $wpdb; |
| 316 | 313 | $forum = bbp_get_forum_post_type() ; |
| 317 | 314 | $forums=$wpdb->get_col("select ID from $wpdb->posts where post_type='$forum'") ; |
| 318 | 315 | $countu=0 ; |
| @@ -329,10 +326,9 @@ | ||
| 329 | 326 | |
| 330 | 327 | } |
| 331 | 328 | echo '</ul></i>' ; |
| 332 | 329 | |
| 333 | - _e('No. forums that have this group set : ', 'bbp-private-groups' ) ; | |
| 334 | - echo $countu ; | |
| 330 | + echo 'No. forums that have this group set : '.$countu ; | |
| 335 | 331 | ?> |
| 336 | 332 | </td></tr> |
| 337 | 333 | <?php } |
| 338 | 334 | |
| @@ -398,39 +394,33 @@ | ||
| 398 | 394 | /***************************** Checkbox functions **************************/ |
| 399 | 395 | function activate_forum_visibility_checkbox() { |
| 400 | 396 | global $rpg_settingsf ; |
| 401 | 397 | $item5 = $rpg_settingsf['set_forum_visibility'] ; |
| 402 | - echo '<input name="rpg_settingsf[set_forum_visibility]" id="rpg_settingsf[set_forum_visibility]" type="checkbox" value="1" class="code" ' . checked( 1,$item5, false ) . ' />' ; | |
| 403 | - _e ('Click to activate forum visibility' , 'bbp-private-groups') ; | |
| 398 | + echo '<input name="rpg_settingsf[set_forum_visibility]" id="rpg_settingsf[set_forum_visibility]" type="checkbox" value="1" class="code" ' . checked( 1,$item5, false ) . ' /> Click to activate forum visibility'; | |
| 404 | 399 | } |
| 405 | 400 | function freshness_checkbox() { |
| 406 | 401 | global $rpg_settingsf ; |
| 407 | 402 | $item4 = $rpg_settingsf['set_freshness_message'] ; |
| 408 | - echo '<input name="rpg_settingsf[set_freshness_message]" id="rpg_settingsf[set_freshness_message]" type="checkbox" value="1" class="code" ' . checked( 1,$item4, false ) . ' />' ; | |
| 409 | - _e ('Click to activate a freshness message', 'bbp-private-groups' ); | |
| 403 | + echo '<input name="rpg_settingsf[set_freshness_message]" id="rpg_settingsf[set_freshness_message]" type="checkbox" value="1" class="code" ' . checked( 1,$item4, false ) . ' /> Click to activate a freshness message'; | |
| 410 | 404 | } |
| 411 | 405 | |
| 412 | 406 | function activate_hide_counts_checkbox() { |
| 413 | 407 | global $rpg_settingsg ; |
| 414 | 408 | $item1 = $rpg_settingsg['hide_counts'] ; |
| 415 | - echo '<input name="rpg_settingsg[hide_counts]" id="rpg_settingsg[hide_counts]" type="checkbox" value="1" class="code" ' . checked( 1,$item1, false ) . ' />' ; | |
| 416 | - _e ('Hide topic and reply counts', 'bbp-private-groups' ); | |
| 409 | + echo '<input name="rpg_settingsg[hide_counts]" id="rpg_settingsg[hide_counts]" type="checkbox" value="1" class="code" ' . checked( 1,$item1, false ) . ' /> Hide topic and reply counts'; | |
| 417 | 410 | } |
| 418 | 411 | function activate_descriptions_checkbox() { |
| 419 | 412 | global $rpg_settingsg ; |
| 420 | 413 | $item2 = $rpg_settingsg['activate_descriptions'] ; |
| 421 | - echo '<input name="rpg_settingsg[activate_descriptions]" id="rpg_settingsg[activate_descriptions]" type="checkbox" value="1" class="code" ' . checked( 1,$item2, false ) . ' />' ; | |
| 422 | - _e ('Show forum content (Descriptions) on main index' , 'bbp-private-groups' ); | |
| 414 | + echo '<input name="rpg_settingsg[activate_descriptions]" id="rpg_settingsg[activate_descriptions]" type="checkbox" value="1" class="code" ' . checked( 1,$item2, false ) . ' /> Show forum content (Descriptions) on main index'; | |
| 423 | 415 | } |
| 424 | 416 | function activate_private_prefix_checkbox() { |
| 425 | 417 | global $rpg_settingsg ; |
| 426 | 418 | $item3 = $rpg_settingsg['activate_remove_private_prefix'] ; |
| 427 | - echo '<input name="rpg_settingsg[activate_remove_private_prefix]" id="rpg_settingsg[activate_remove_private_prefix]" type="checkbox" value="1" class="code" ' . checked( 1,$item3, false ) . ' />' ; | |
| 428 | - _e ('Remove Private prefix' , 'bbp-private-groups' ); | |
| 419 | + echo '<input name="rpg_settingsg[activate_remove_private_prefix]" id="rpg_settingsg[activate_remove_private_prefix]" type="checkbox" value="1" class="code" ' . checked( 1,$item3, false ) . ' /> Remove Private prefix'; | |
| 429 | 420 | } |
| 430 | 421 | function activate_new_group() { |
| 431 | 422 | global $rpg_groups ; |
| 432 | 423 | $item6 = $rpg_groups['activate_new_group'] ; |
| 433 | - echo '<input name="rpg_groups[activate_new_group]" id="rpg_groups[activate_new_group]" type="checkbox" value="1" class="code" />' ; | |
| 434 | - _e ('Click and then press "save groups" to add a new group' , 'bbp-private-groups' ) ; | |
| 424 | + echo '<input name="rpg_groups[activate_new_group]" id="rpg_groups[activate_new_group]" type="checkbox" value="1" class="code" /> Click and then press "save groups" to add a new group' ; | |
| 435 | 425 | } |
| 436 | 426 | |