Changeset 4950
- Timestamp:
- 05/27/2013 06:16:35 AM (13 years ago)
- Location:
- trunk/includes/admin
- Files:
-
- 10 edited
-
admin.php (modified) (13 diffs)
-
converter.php (modified) (2 diffs)
-
forums.php (modified) (2 diffs)
-
functions.php (modified) (1 diff)
-
metaboxes.php (modified) (13 diffs)
-
replies.php (modified) (10 diffs)
-
settings.php (modified) (49 diffs)
-
tools.php (modified) (4 diffs)
-
topics.php (modified) (10 diffs)
-
users.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/includes/admin/admin.php
r4949 r4950 1336 1336 1337 1337 <div class="wrap about-wrap"> 1338 <h1><?php printf( __( 'Welcome to bbPress %s', 'bbpress' ), $display_version ); ?></h1>1339 <div class="about-text"><?php printf( __( 'Thank you for updating to the latest version! bbPress %s goes great with pizza and popcorn, and will nicely complement your community too!', 'bbpress' ), $display_version ); ?></div>1340 <div class="bbp-badge"><?php printf( __( 'Version %s', 'bbpress' ), $display_version ); ?></div>1338 <h1><?php printf( esc_html__( 'Welcome to bbPress %s', 'bbpress' ), $display_version ); ?></h1> 1339 <div class="about-text"><?php printf( esc_html__( 'Thank you for updating to the latest version! bbPress %s goes great with pizza and popcorn, and will nicely complement your community too!', 'bbpress' ), $display_version ); ?></div> 1340 <div class="bbp-badge"><?php printf( esc_html__( 'Version %s', 'bbpress' ), $display_version ); ?></div> 1341 1341 1342 1342 <h2 class="nav-tab-wrapper"> 1343 1343 <a class="nav-tab nav-tab-active" href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbp-about' ), 'index.php' ) ) ); ?>"> 1344 <?php _e( 'What’s New', 'bbpress' ); ?>1344 <?php esc_html_e( 'What’s New', 'bbpress' ); ?> 1345 1345 </a><a class="nav-tab" href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbp-credits' ), 'index.php' ) ) ); ?>"> 1346 <?php _e( 'Credits', 'bbpress' ); ?>1346 <?php esc_html_e( 'Credits', 'bbpress' ); ?> 1347 1347 </a> 1348 1348 </h2> 1349 1349 1350 1350 <div class="changelog"> 1351 <h3><?php _e( 'Forum Search', 'bbpress' ); ?></h3>1351 <h3><?php esc_html_e( 'Forum Search', 'bbpress' ); ?></h3> 1352 1352 1353 1353 <div class="feature-section"> 1354 <h4><?php _e( 'Only Forum Content', 'bbpress' ); ?></h4>1355 <p><?php _e( 'Allow your forums to be searched without mixing in your posts or pages.', 'bbpress' ); ?></p>1356 1357 <h4><?php _e( 'Choose Your Own Slug', 'bbpress' ); ?></h4>1358 <p><?php _e( 'Setup your forum search to live anywhere relative to the forum index.', 'bbpress' ); ?></p>1354 <h4><?php esc_html_e( 'Only Forum Content', 'bbpress' ); ?></h4> 1355 <p><?php esc_html_e( 'Allow your forums to be searched without mixing in your posts or pages.', 'bbpress' ); ?></p> 1356 1357 <h4><?php esc_html_e( 'Choose Your Own Slug', 'bbpress' ); ?></h4> 1358 <p><?php esc_html_e( 'Setup your forum search to live anywhere relative to the forum index.', 'bbpress' ); ?></p> 1359 1359 </div> 1360 1360 </div> 1361 1361 1362 1362 <div class="changelog"> 1363 <h3><?php _e( 'New & Improved Forum Importers', 'bbpress' ); ?></h3>1363 <h3><?php esc_html_e( 'New & Improved Forum Importers', 'bbpress' ); ?></h3> 1364 1364 1365 1365 <div class="feature-section"> 1366 <h4><?php _e( 'BBCodes & Smilies', 'bbpress' ); ?></h4>1367 <p><?php _e( 'Happy faces all-around now that the importers properly convert BBCodes & smilies. :)', 'bbpress' ); ?></p>1368 1369 <h4><?php _e( 'Vanilla', 'bbpress' ); ?></h4>1370 <p><?php _e( 'Tired of plain old Vanilla? Now you can easily switch to <del>Mint Chocolate Chip</del> bbPress!', 'bbpress' ); ?></p>1371 1372 <h4><?php _e( 'SimplePress', 'bbpress' ); ?></h4>1373 <p><?php _e( 'Converting an existing SimplePress powered forum to bbPress has never been "simpler!"', 'bbpress' ); ?></p>1374 1375 <h4><?php _e( 'Mingle', 'bbpress' ); ?></h4>1376 <p><?php _e( 'No time to... chit-chat; convert your Mingle forums to bbPress today!', 'bbpress' ); ?></p>1366 <h4><?php esc_html_e( 'BBCodes & Smilies', 'bbpress' ); ?></h4> 1367 <p><?php esc_html_e( 'Happy faces all-around now that the importers properly convert BBCodes & smilies. :)', 'bbpress' ); ?></p> 1368 1369 <h4><?php esc_html_e( 'Vanilla', 'bbpress' ); ?></h4> 1370 <p><?php esc_html_e( 'Tired of plain old Vanilla? Now you can easily switch to <del>Mint Chocolate Chip</del> bbPress!', 'bbpress' ); ?></p> 1371 1372 <h4><?php esc_html_e( 'SimplePress', 'bbpress' ); ?></h4> 1373 <p><?php esc_html_e( 'Converting an existing SimplePress powered forum to bbPress has never been "simpler!"', 'bbpress' ); ?></p> 1374 1375 <h4><?php esc_html_e( 'Mingle', 'bbpress' ); ?></h4> 1376 <p><?php esc_html_e( 'No time to... chit-chat; convert your Mingle forums to bbPress today!', 'bbpress' ); ?></p> 1377 1377 </div> 1378 1378 </div> 1379 1379 1380 1380 <div class="changelog"> 1381 <h3><?php _e( 'Even Better BuddyPress Integration', 'bbpress' ); ?></h3>1381 <h3><?php esc_html_e( 'Even Better BuddyPress Integration', 'bbpress' ); ?></h3> 1382 1382 1383 1383 <div class="feature-section"> 1384 <h4><?php _e( 'bbPress powered BuddyPress Group Forums', 'bbpress' ); ?></h4>1385 <p><?php _e( 'Use bbPress to manage your BuddyPress Group Forums, allowing for seamless integration and improved plugin performance.', 'bbpress' ); ?></p>1384 <h4><?php esc_html_e( 'bbPress powered BuddyPress Group Forums', 'bbpress' ); ?></h4> 1385 <p><?php esc_html_e( 'Use bbPress to manage your BuddyPress Group Forums, allowing for seamless integration and improved plugin performance.', 'bbpress' ); ?></p> 1386 1386 </div> 1387 1387 </div> 1388 1388 1389 1389 <div class="changelog"> 1390 <h3><?php _e( 'Under the Hood', 'bbpress' ); ?></h3>1390 <h3><?php esc_html_e( 'Under the Hood', 'bbpress' ); ?></h3> 1391 1391 1392 1392 <div class="feature-section col three-col"> 1393 1393 <div> 1394 <h4><?php _e( 'Smarter Fancy Editor', 'bbpress' ); ?></h4>1395 <p><?php _e( 'We simplified the Fancy Editor, and the allowed HTML tags that work with it.', 'bbpress' ); ?></p>1396 1397 <h4><?php _e( 'Better Code Posting', 'bbpress' ); ?></h4>1398 <p><?php _e( 'Your users can now post code snippets without too much hassle.', 'bbpress' ); ?></p>1394 <h4><?php esc_html_e( 'Smarter Fancy Editor', 'bbpress' ); ?></h4> 1395 <p><?php esc_html_e( 'We simplified the Fancy Editor, and the allowed HTML tags that work with it.', 'bbpress' ); ?></p> 1396 1397 <h4><?php esc_html_e( 'Better Code Posting', 'bbpress' ); ?></h4> 1398 <p><?php esc_html_e( 'Your users can now post code snippets without too much hassle.', 'bbpress' ); ?></p> 1399 1399 </div> 1400 1400 1401 1401 <div> 1402 <h4><?php _e( 'Template Stacking', 'bbpress' ); ?></h4>1403 <p><?php _e( 'Now you can replace specific template parts on the fly without modifying the existing theme.', 'bbpress' ); ?></p>1404 1405 <h4><?php _e( 'TwentyThirteen Tested', 'bbpress' ); ?></h4>1406 <p><?php _e( 'bbPress 2.3 already works with the in-development TwentyThirteen theme, coming in a future version of WordPress.', 'bbpress' ); ?></p>1402 <h4><?php esc_html_e( 'Template Stacking', 'bbpress' ); ?></h4> 1403 <p><?php esc_html_e( 'Now you can replace specific template parts on the fly without modifying the existing theme.', 'bbpress' ); ?></p> 1404 1405 <h4><?php esc_html_e( 'TwentyThirteen Tested', 'bbpress' ); ?></h4> 1406 <p><?php esc_html_e( 'bbPress 2.3 already works with the in-development TwentyThirteen theme, coming in a future version of WordPress.', 'bbpress' ); ?></p> 1407 1407 </div> 1408 1408 1409 1409 <div class="last-feature"> 1410 <h4><?php _e( 'Statistics Shortcode', 'bbpress' ); ?></h4>1411 <p><?php _e( 'The old statistics easter-egg page was turned into an easy to use shortcode.', 'bbpress' ); ?></p>1412 1413 <h4><?php _e( 'Green Theme Updated', 'bbpress' ); ?></h4>1414 <p><?php _e( 'The green admin theme easter-egg was updated to work with WordPress 3.5 changes.', 'bbpress' ); ?></p>1410 <h4><?php esc_html_e( 'Statistics Shortcode', 'bbpress' ); ?></h4> 1411 <p><?php esc_html_e( 'The old statistics easter-egg page was turned into an easy to use shortcode.', 'bbpress' ); ?></p> 1412 1413 <h4><?php esc_html_e( 'Green Theme Updated', 'bbpress' ); ?></h4> 1414 <p><?php esc_html_e( 'The green admin theme easter-egg was updated to work with WordPress 3.5 changes.', 'bbpress' ); ?></p> 1415 1415 </div> 1416 1416 </div> … … 1418 1418 1419 1419 <div class="return-to-dashboard"> 1420 <a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbpress' ), 'options-general.php' ) ) ); ?>"><?php _e( 'Go to Forum Settings', 'bbpress' ); ?></a>1420 <a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbpress' ), 'options-general.php' ) ) ); ?>"><?php esc_html_e( 'Go to Forum Settings', 'bbpress' ); ?></a> 1421 1421 </div> 1422 1422 … … 1445 1445 <h2 class="nav-tab-wrapper"> 1446 1446 <a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbp-about' ), 'index.php' ) ) ); ?>" class="nav-tab"> 1447 <?php _e( 'What’s New', 'bbpress' ); ?>1447 <?php esc_html_e( 'What’s New', 'bbpress' ); ?> 1448 1448 </a><a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbp-credits' ), 'index.php' ) ) ); ?>" class="nav-tab nav-tab-active"> 1449 <?php _e( 'Credits', 'bbpress' ); ?>1449 <?php esc_html_e( 'Credits', 'bbpress' ); ?> 1450 1450 </a> 1451 1451 </h2> 1452 1452 1453 <p class="about-description"><?php _e( 'bbPress is created by a worldwide swarm of busy, busy bees.', 'bbpress' ); ?></p>1454 1455 <h4 class="wp-people-group"><?php _e( 'Project Leaders', 'bbpress' ); ?></h4>1453 <p class="about-description"><?php esc_html_e( 'bbPress is created by a worldwide swarm of busy, busy bees.', 'bbpress' ); ?></p> 1454 1455 <h4 class="wp-people-group"><?php esc_html_e( 'Project Leaders', 'bbpress' ); ?></h4> 1456 1456 <ul class="wp-people-group " id="wp-people-group-project-leaders"> 1457 1457 <li class="wp-person" id="wp-person-matt"> 1458 1458 <a href="http://profiles.wordpress.org/matt"><img src="http://0.gravatar.com/avatar/767fc9c115a1b989744c755db47feb60?s=60" class="gravatar" alt="Matt Mullenweg" /></a> 1459 1459 <a class="web" href="http://profiles.wordpress.org/matt">Matt Mullenweg</a> 1460 <span class="title"><?php _e( 'Founding Developer', 'bbpress' ); ?></span>1460 <span class="title"><?php esc_html_e( 'Founding Developer', 'bbpress' ); ?></span> 1461 1461 </li> 1462 1462 <li class="wp-person" id="wp-person-johnjamesjacoby"> 1463 1463 <a href="http://profiles.wordpress.org/johnjamesjacoby"><img src="http://0.gravatar.com/avatar/81ec16063d89b162d55efe72165c105f?s=60" class="gravatar" alt="John James Jacoby" /></a> 1464 1464 <a class="web" href="http://profiles.wordpress.org/johnjamesjacoby">John James Jacoby</a> 1465 <span class="title"><?php _e( 'Lead Developer', 'bbpress' ); ?></span>1465 <span class="title"><?php esc_html_e( 'Lead Developer', 'bbpress' ); ?></span> 1466 1466 </li> 1467 1467 <li class="wp-person" id="wp-person-jmdodd"> … … 1472 1472 </ul> 1473 1473 1474 <h4 class="wp-people-group"><?php _e( 'Contributing Developers', 'bbpress' ); ?></h4>1474 <h4 class="wp-people-group"><?php esc_html_e( 'Contributing Developers', 'bbpress' ); ?></h4> 1475 1475 <ul class="wp-people-group " id="wp-people-group-contributing-developers"> 1476 1476 <li class="wp-person" id="wp-person-netweb"> … … 1491 1491 </ul> 1492 1492 1493 <h4 class="wp-people-group"><?php _e( 'Core Contributors to bbPress 2.3', 'bbpress' ); ?></h4>1493 <h4 class="wp-people-group"><?php esc_html_e( 'Core Contributors to bbPress 2.3', 'bbpress' ); ?></h4> 1494 1494 <p class="wp-credits-list"> 1495 1495 <a href="http://profiles.wordpress.org/alexvorn2">alexvorn2</a>, … … 1532 1532 1533 1533 <div class="return-to-dashboard"> 1534 <a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbpress' ), 'options-general.php' ) ) ); ?>"><?php _e( 'Go to Forum Settings', 'bbpress' ); ?></a>1534 <a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'bbpress' ), 'options-general.php' ) ) ); ?>"><?php esc_html_e( 'Go to Forum Settings', 'bbpress' ); ?></a> 1535 1535 </div> 1536 1536 … … 1558 1558 <div class="wrap"> 1559 1559 <div id="icon-edit" class="icon32 icon32-posts-topic"><br /></div> 1560 <h2><?php _e( 'Update Forum', 'bbpress' ); ?></h2>1560 <h2><?php esc_html_e( 'Update Forum', 'bbpress' ); ?></h2> 1561 1561 1562 1562 <?php … … 1569 1569 bbp_version_updater(); ?> 1570 1570 1571 <p><?php _e( 'All done!', 'bbpress' ); ?></p>1572 <a class="button" href="index.php?page=bbp-update"><?php _e( 'Go Back', 'bbpress' ); ?></a>1571 <p><?php esc_html_e( 'All done!', 'bbpress' ); ?></p> 1572 <a class="button" href="index.php?page=bbp-update"><?php esc_html_e( 'Go Back', 'bbpress' ); ?></a> 1573 1573 1574 1574 <?php … … 1579 1579 default : ?> 1580 1580 1581 <p><?php _e( 'You can update your forum through this page. Hit the link below to update.', 'bbpress' ); ?></p>1582 <p><a class="button" href="index.php?page=bbp-update&action=bbp-update"><?php _e( 'Update Forum', 'bbpress' ); ?></a></p>1581 <p><?php esc_html_e( 'You can update your forum through this page. Hit the link below to update.', 'bbpress' ); ?></p> 1582 <p><a class="button" href="index.php?page=bbp-update&action=bbp-update"><?php esc_html_e( 'Update Forum', 'bbpress' ); ?></a></p> 1583 1583 1584 1584 <?php break; … … 1606 1606 <div class="wrap"> 1607 1607 <div id="icon-edit" class="icon32 icon32-posts-topic"><br /></div> 1608 <h2><?php _e( 'Update Forums', 'bbpress' ); ?></h2>1608 <h2><?php esc_html_e( 'Update Forums', 'bbpress' ); ?></h2> 1609 1609 1610 1610 <?php … … 1623 1623 if ( empty( $blogs ) ) : ?> 1624 1624 1625 <p><?php _e( 'All done!', 'bbpress' ); ?></p>1626 <a class="button" href="update-core.php?page=bbpress-update"><?php _e( 'Go Back', 'bbpress' ); ?></a>1625 <p><?php esc_html_e( 'All done!', 'bbpress' ); ?></p> 1626 <a class="button" href="update-core.php?page=bbpress-update"><?php esc_html_e( 'Go Back', 'bbpress' ); ?></a> 1627 1627 1628 1628 <?php break; ?> … … 1675 1675 1676 1676 <p> 1677 <?php _e( 'If your browser doesn’t start loading the next page automatically, click this link:', 'bbpress' ); ?>1678 <a class="button" href="update-core.php?page=bbpress-update&action=bbpress-update&n=<?php echo ( $n + 5 ); ?>"><?php _e( 'Next Forums', 'bbpress' ); ?></a>1677 <?php esc_html_e( 'If your browser doesn’t start loading the next page automatically, click this link:', 'bbpress' ); ?> 1678 <a class="button" href="update-core.php?page=bbpress-update&action=bbpress-update&n=<?php echo ( $n + 5 ); ?>"><?php esc_html_e( 'Next Forums', 'bbpress' ); ?></a> 1679 1679 </p> 1680 1680 <script type='text/javascript'> … … 1694 1694 default : ?> 1695 1695 1696 <p><?php _e( 'You can update all the forums on your network through this page. It works by calling the update script of each site automatically. Hit the link below to update.', 'bbpress' ); ?></p>1697 <p><a class="button" href="update-core.php?page=bbpress-update&action=bbpress-update"><?php _e( 'Update Forums', 'bbpress' ); ?></a></p>1696 <p><?php esc_html_e( 'You can update all the forums on your network through this page. It works by calling the update script of each site automatically. Hit the link below to update.', 'bbpress' ); ?></p> 1697 <p><a class="button" href="update-core.php?page=bbpress-update&action=bbpress-update"><?php esc_html_e( 'Update Forums', 'bbpress' ); ?></a></p> 1698 1698 1699 1699 <?php break; -
trunk/includes/admin/converter.php
r4824 r4950 221 221 jQuery('#bbp-converter-stop').show(); 222 222 jQuery('#bbp-converter-progress').show(); 223 bbconverter_log( '<p class="loading"><?php _e( 'Starting Conversion', 'bbpress' ); ?></p>' );223 bbconverter_log( '<p class="loading"><?php esc_html_e( 'Starting Conversion', 'bbpress' ); ?></p>' ); 224 224 bbconverter_run(); 225 225 } … … 246 246 bbconverter_log(response); 247 247 248 if ( response == '<p class="loading"><?php _e( 'Conversion Complete', 'bbpress' ); ?></p>' || response.indexOf('error') > -1 ) {248 if ( response == '<p class="loading"><?php esc_html_e( 'Conversion Complete', 'bbpress' ); ?></p>' || response.indexOf('error') > -1 ) { 249 249 bbconverter_log('<p>Repair any missing information: <a href="<?php echo admin_url(); ?>tools.php?page=bbp-repair">Continue</a></p>'); 250 250 bbconverter_stop(); -
trunk/includes/admin/forums.php
r4909 r4950 449 449 450 450 case 'bbp_forum_created': 451 printf( __( '%1$s <br /> %2$s', 'bbpress' ),451 printf( '%1$s <br /> %2$s', 452 452 get_the_date(), 453 453 esc_attr( get_the_time() ) … … 459 459 $last_active = bbp_get_forum_last_active_time( $forum_id, false ); 460 460 if ( !empty( $last_active ) ) 461 echo $last_active;461 echo esc_html( $last_active ); 462 462 else 463 _e( 'No Topics', 'bbpress' );463 esc_html_e( 'No Topics', 'bbpress' ); 464 464 465 465 break; -
trunk/includes/admin/functions.php
r4835 r4950 247 247 248 248 // Loop through tabs and build navigation 249 foreach( $tabs as $tab_id =>$tab_data ) {249 foreach( array_values( $tabs ) as $tab_data ) { 250 250 $is_current = (bool) ( $tab_data['name'] == $active_tab ); 251 251 $tab_class = $is_current ? $active_class : $idle_class; 252 $tabs_html .= '<a href="' . $tab_data['href'] . '" class="' . $tab_class . '">' . $tab_data['name']. '</a>';252 $tabs_html .= '<a href="' . esc_url( $tab_data['href'] ) . '" class="' . esc_attr( $tab_class ) . '">' . esc_html( $tab_data['name'] ) . '</a>'; 253 253 } 254 254 -
trunk/includes/admin/metaboxes.php
r4944 r4950 40 40 <div class="table table_content"> 41 41 42 <p class="sub"><?php _e( 'Discussion', 'bbpress' ); ?></p>42 <p class="sub"><?php esc_html_e( 'Discussion', 'bbpress' ); ?></p> 43 43 44 44 <table> … … 125 125 <div class="table table_discussion"> 126 126 127 <p class="sub"><?php _e( 'Users & Moderation', 'bbpress' ); ?></p>127 <p class="sub"><?php esc_html_e( 'Users & Moderation', 'bbpress' ); ?></p> 128 128 129 129 <table> … … 259 259 260 260 <p> 261 <strong class="label"><?php _e( 'Type:', 'bbpress' ); ?></strong>262 <label class="screen-reader-text" for="bbp_forum_type_select"><?php _e( 'Type:', 'bbpress' ) ?></label>261 <strong class="label"><?php esc_html_e( 'Type:', 'bbpress' ); ?></strong> 262 <label class="screen-reader-text" for="bbp_forum_type_select"><?php esc_html_e( 'Type:', 'bbpress' ) ?></label> 263 263 <?php bbp_form_forum_type_dropdown( $post_id ); ?> 264 264 </p> … … 271 271 272 272 <p> 273 <strong class="label"><?php _e( 'Status:', 'bbpress' ); ?></strong>274 <label class="screen-reader-text" for="bbp_forum_status_select"><?php _e( 'Status:', 'bbpress' ) ?></label>273 <strong class="label"><?php esc_html_e( 'Status:', 'bbpress' ); ?></strong> 274 <label class="screen-reader-text" for="bbp_forum_status_select"><?php esc_html_e( 'Status:', 'bbpress' ) ?></label> 275 275 <?php bbp_form_forum_status_dropdown( $post_id ); ?> 276 276 </p> … … 283 283 284 284 <p> 285 <strong class="label"><?php _e( 'Visibility:', 'bbpress' ); ?></strong>286 <label class="screen-reader-text" for="bbp_forum_visibility_select"><?php _e( 'Visibility:', 'bbpress' ) ?></label>285 <strong class="label"><?php esc_html_e( 'Visibility:', 'bbpress' ); ?></strong> 286 <label class="screen-reader-text" for="bbp_forum_visibility_select"><?php esc_html_e( 'Visibility:', 'bbpress' ) ?></label> 287 287 <?php bbp_form_forum_visibility_dropdown( $post_id ); ?> 288 288 </p> … … 297 297 298 298 <p> 299 <strong class="label"><?php _e( 'Parent:', 'bbpress' ); ?></strong>300 <label class="screen-reader-text" for="parent_id"><?php _e( 'Forum Parent', 'bbpress' ); ?></label>299 <strong class="label"><?php esc_html_e( 'Parent:', 'bbpress' ); ?></strong> 300 <label class="screen-reader-text" for="parent_id"><?php esc_html_e( 'Forum Parent', 'bbpress' ); ?></label> 301 301 <?php bbp_dropdown( array( 302 302 'post_type' => bbp_get_forum_post_type(), … … 320 320 321 321 <p> 322 <strong class="label"><?php _e( 'Order:', 'bbpress' ); ?></strong>323 <label class="screen-reader-text" for="menu_order"><?php _e( 'Forum Order', 'bbpress' ); ?></label>322 <strong class="label"><?php esc_html_e( 'Order:', 'bbpress' ); ?></strong> 323 <label class="screen-reader-text" for="menu_order"><?php esc_html_e( 'Forum Order', 'bbpress' ); ?></label> 324 324 <input name="menu_order" type="number" step="1" size="4" id="menu_order" value="<?php echo esc_attr( $menu_order ); ?>" /> 325 325 </p> … … 348 348 349 349 <p> 350 <strong class="label"><?php _e( 'Type:', 'bbpress' ); ?></strong>351 <label class="screen-reader-text" for="bbp_stick_topic"><?php _e( 'Topic Type', 'bbpress' ); ?></label>350 <strong class="label"><?php esc_html_e( 'Type:', 'bbpress' ); ?></strong> 351 <label class="screen-reader-text" for="bbp_stick_topic"><?php esc_html_e( 'Topic Type', 'bbpress' ); ?></label> 352 352 <?php bbp_topic_type_select( array( 'topic_id' => $post_id ) ); ?> 353 353 </p> 354 354 355 355 <p> 356 <strong class="label"><?php _e( 'Forum:', 'bbpress' ); ?></strong>357 <label class="screen-reader-text" for="parent_id"><?php _e( 'Forum', 'bbpress' ); ?></label>356 <strong class="label"><?php esc_html_e( 'Forum:', 'bbpress' ); ?></strong> 357 <label class="screen-reader-text" for="parent_id"><?php esc_html_e( 'Forum', 'bbpress' ); ?></label> 358 358 <?php bbp_dropdown( array( 359 359 'post_type' => bbp_get_forum_post_type(), … … 407 407 408 408 <p> 409 <strong class="label"><?php _e( 'Forum:', 'bbpress' ); ?></strong>410 <label class="screen-reader-text" for="bbp_forum_id"><?php _e( 'Forum', 'bbpress' ); ?></label>409 <strong class="label"><?php esc_html_e( 'Forum:', 'bbpress' ); ?></strong> 410 <label class="screen-reader-text" for="bbp_forum_id"><?php esc_html_e( 'Forum', 'bbpress' ); ?></label> 411 411 <?php bbp_dropdown( array( 412 412 'post_type' => bbp_get_forum_post_type(), … … 432 432 433 433 <p> 434 <strong class="label"><?php _e( 'Topic:', 'bbpress' ); ?></strong>435 <label class="screen-reader-text" for="parent_id"><?php _e( 'Topic', 'bbpress' ); ?></label>434 <strong class="label"><?php esc_html_e( 'Topic:', 'bbpress' ); ?></strong> 435 <label class="screen-reader-text" for="parent_id"><?php esc_html_e( 'Topic', 'bbpress' ); ?></label> 436 436 <input name="parent_id" id="bbp_topic_id" type="text" value="<?php echo esc_attr( $reply_topic_id ); ?>" /> 437 437 </p> 438 438 439 439 <p> 440 <strong class="label"><?php _e( 'Reply To:', 'bbpress' ); ?></strong>441 <label class="screen-reader-text" for="bbp_reply_to"><?php _e( 'Reply To', 'bbpress' ); ?></label>440 <strong class="label"><?php esc_html_e( 'Reply To:', 'bbpress' ); ?></strong> 441 <label class="screen-reader-text" for="bbp_reply_to"><?php esc_html_e( 'Reply To', 'bbpress' ); ?></label> 442 442 <input name="bbp_reply_to" id="bbp_reply_to" type="text" value="<?php echo esc_attr( $reply_to ); ?>" /> 443 443 </p> … … 469 469 470 470 <p> 471 <strong class="label"><?php _e( 'Name:', 'bbpress' ); ?></strong>472 <label class="screen-reader-text" for="bbp_anonymous_name"><?php _e( 'Name', 'bbpress' ); ?></label>471 <strong class="label"><?php esc_html_e( 'Name:', 'bbpress' ); ?></strong> 472 <label class="screen-reader-text" for="bbp_anonymous_name"><?php esc_html_e( 'Name', 'bbpress' ); ?></label> 473 473 <input type="text" id="bbp_anonymous_name" name="bbp_anonymous_name" value="<?php echo esc_attr( get_post_meta( $post_id, '_bbp_anonymous_name', true ) ); ?>" /> 474 474 </p> 475 475 476 476 <p> 477 <strong class="label"><?php _e( 'Email:', 'bbpress' ); ?></strong>478 <label class="screen-reader-text" for="bbp_anonymous_email"><?php _e( 'Email', 'bbpress' ); ?></label>477 <strong class="label"><?php esc_html_e( 'Email:', 'bbpress' ); ?></strong> 478 <label class="screen-reader-text" for="bbp_anonymous_email"><?php esc_html_e( 'Email', 'bbpress' ); ?></label> 479 479 <input type="text" id="bbp_anonymous_email" name="bbp_anonymous_email" value="<?php echo esc_attr( get_post_meta( $post_id, '_bbp_anonymous_email', true ) ); ?>" /> 480 480 </p> 481 481 482 482 <p> 483 <strong class="label"><?php _e( 'Website:', 'bbpress' ); ?></strong>484 <label class="screen-reader-text" for="bbp_anonymous_website"><?php _e( 'Website', 'bbpress' ); ?></label>483 <strong class="label"><?php esc_html_e( 'Website:', 'bbpress' ); ?></strong> 484 <label class="screen-reader-text" for="bbp_anonymous_website"><?php esc_html_e( 'Website', 'bbpress' ); ?></label> 485 485 <input type="text" id="bbp_anonymous_website" name="bbp_anonymous_website" value="<?php echo esc_attr( get_post_meta( $post_id, '_bbp_anonymous_website', true ) ); ?>" /> 486 486 </p> … … 489 489 490 490 <p> 491 <strong class="label"><?php _e( 'Name:', 'bbpress' ); ?></strong>492 <label class="screen-reader-text" for="bbp_author_name"><?php _e( 'Name', 'bbpress' ); ?></label>491 <strong class="label"><?php esc_html_e( 'Name:', 'bbpress' ); ?></strong> 492 <label class="screen-reader-text" for="bbp_author_name"><?php esc_html_e( 'Name', 'bbpress' ); ?></label> 493 493 <input type="text" id="bbp_author_name" name="bbp_author_name" value="<?php echo esc_attr( get_the_author_meta( 'nicename', bbp_get_global_post_field( 'post_author' ) ) ); ?>" disabled="disabled" /> 494 494 </p> 495 495 496 496 <p> 497 <strong class="label"><?php _e( 'Email:', 'bbpress' ); ?></strong>498 <label class="screen-reader-text" for="bbp_author_email"><?php _e( 'Email', 'bbpress' ); ?></label>497 <strong class="label"><?php esc_html_e( 'Email:', 'bbpress' ); ?></strong> 498 <label class="screen-reader-text" for="bbp_author_email"><?php esc_html_e( 'Email', 'bbpress' ); ?></label> 499 499 <input type="text" id="bbp_author_email" name="bbp_author_email" value="<?php echo esc_attr( get_the_author_meta( 'email', bbp_get_global_post_field( 'post_author' ) ) ); ?>" disabled="disabled" /> 500 500 </p> … … 503 503 504 504 <p> 505 <strong class="label"><?php _e( 'IP:', 'bbpress' ); ?></strong>506 <label class="screen-reader-text" for="bbp_author_ip_address"><?php _e( 'IP Address', 'bbpress' ); ?></label>505 <strong class="label"><?php esc_html_e( 'IP:', 'bbpress' ); ?></strong> 506 <label class="screen-reader-text" for="bbp_author_ip_address"><?php esc_html_e( 'IP Address', 'bbpress' ); ?></label> 507 507 <input type="text" id="bbp_author_ip_address" name="bbp_author_ip_address" value="<?php echo esc_attr( get_post_meta( $post_id, '_bbp_author_ip', true ) ); ?>" disabled="disabled" /> 508 508 </p> -
trunk/includes/admin/replies.php
r4944 r4950 526 526 return; 527 527 528 $reply_title = esc_html( bbp_get_reply_title( $reply->ID ));528 $reply_title = bbp_get_reply_title( $reply->ID ); 529 529 530 530 switch ( $notice ) { … … 544 544 545 545 <div id="message" class="<?php echo $is_failure == true ? 'error' : 'updated'; ?> fade"> 546 <p style="line-height: 150%"><?php echo $message; ?></p>546 <p style="line-height: 150%"><?php echo esc_html( $message ); ?></p> 547 547 </div> 548 548 … … 624 624 $topic_title = bbp_get_topic_title( $topic_id ); 625 625 if ( empty( $topic_title ) ) { 626 $topic_title = __( 'No Topic', 'bbpress' );626 $topic_title = esc_html__( 'No Topic', 'bbpress' ); 627 627 } 628 628 … … 632 632 // Reply has no topic 633 633 } else { 634 _e( 'No Topic', 'bbpress' );634 esc_html_e( 'No Topic', 'bbpress' ); 635 635 } 636 636 … … 650 650 $forum_title = bbp_get_forum_title( $reply_forum_id ); 651 651 if ( empty( $forum_title ) ) { 652 $forum_title = __( 'No Forum', 'bbpress' );652 $forum_title = esc_html__( 'No Forum', 'bbpress' ); 653 653 } 654 654 … … 656 656 if ( $reply_forum_id != $topic_forum_id ) { 657 657 if ( current_user_can( 'edit_others_replies' ) || current_user_can( 'moderate' ) ) { 658 $forum_title .= '<div class="attention">' . __( '(Mismatch)', 'bbpress' ) . '</div>';658 $forum_title .= '<div class="attention">' . esc_html__( '(Mismatch)', 'bbpress' ) . '</div>'; 659 659 } 660 660 } … … 679 679 680 680 // Output last activity time and date 681 printf( __( '%1$s <br /> %2$s', 'bbpress' ),681 printf( '%1$s <br /> %2$s', 682 682 get_the_date(), 683 683 esc_attr( get_the_time() ) … … 724 724 725 725 // Reply view links to topic 726 $actions['view'] = '<a href="' . bbp_get_reply_url( $reply->ID ) . '" title="' . esc_attr( sprintf( __( 'View “%s”', 'bbpress' ), bbp_get_reply_title( $reply->ID ) ) ) . '" rel="permalink">' . __( 'View', 'bbpress' ) . '</a>';726 $actions['view'] = '<a href="' . bbp_get_reply_url( $reply->ID ) . '" title="' . esc_attr( sprintf( __( 'View “%s”', 'bbpress' ), bbp_get_reply_title( $reply->ID ) ) ) . '" rel="permalink">' . esc_html__( 'View', 'bbpress' ) . '</a>'; 727 727 728 728 // User cannot view replies in trash … … 733 733 if ( current_user_can( 'moderate', $reply->ID ) ) { 734 734 if ( in_array( $reply->post_status, array( bbp_get_public_status_id(), bbp_get_spam_status_id() ) ) ) { 735 $spam_uri = esc_url( wp_nonce_url( add_query_arg( array( 'reply_id' => $reply->ID, 'action' => 'bbp_toggle_reply_spam' ), remove_query_arg( array( 'bbp_reply_toggle_notice', 'reply_id', 'failed', 'super' ) ) ), 'spam-reply_' . $reply->ID ));735 $spam_uri = wp_nonce_url( add_query_arg( array( 'reply_id' => $reply->ID, 'action' => 'bbp_toggle_reply_spam' ), remove_query_arg( array( 'bbp_reply_toggle_notice', 'reply_id', 'failed', 'super' ) ) ), 'spam-reply_' . $reply->ID ); 736 736 if ( bbp_is_reply_spam( $reply->ID ) ) { 737 $actions['spam'] = '<a href="' . $spam_uri . '" title="' . esc_attr__( 'Mark the reply as not spam', 'bbpress' ) . '">' .__( 'Not spam', 'bbpress' ) . '</a>';737 $actions['spam'] = '<a href="' . esc_url( $spam_uri ) . '" title="' . esc_attr__( 'Mark the reply as not spam', 'bbpress' ) . '">' . esc_html__( 'Not spam', 'bbpress' ) . '</a>'; 738 738 } else { 739 $actions['spam'] = '<a href="' . $spam_uri . '" title="' . esc_attr__( 'Mark this reply as spam', 'bbpress' ) . '">' .__( 'Spam', 'bbpress' ) . '</a>';739 $actions['spam'] = '<a href="' . esc_url( $spam_uri ) . '" title="' . esc_attr__( 'Mark this reply as spam', 'bbpress' ) . '">' . esc_html__( 'Spam', 'bbpress' ) . '</a>'; 740 740 } 741 741 } … … 745 745 if ( current_user_can( 'delete_reply', $reply->ID ) ) { 746 746 if ( bbp_get_trash_status_id() == $reply->post_status ) { 747 $post_type_object = get_post_type_object( bbp_get_reply_post_type() );748 $actions['untrash'] = "<a title='" . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_reply_post_type() ), admin_url( 'edit.php' ) ) ), wp_nonce_url( admin_url( sprintf( $post_type_object->_edit_link . '&action=untrash', $reply->ID ) ), 'untrash-' . $reply->post_type . '_' . $reply->ID ) ) . "'>" . __( 'Restore', 'bbpress' ) . "</a>";747 $post_type_object = get_post_type_object( bbp_get_reply_post_type() ); 748 $actions['untrash'] = "<a title='" . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_reply_post_type() ), admin_url( 'edit.php' ) ) ), wp_nonce_url( admin_url( sprintf( $post_type_object->_edit_link . '&action=untrash', $reply->ID ) ), 'untrash-' . $reply->post_type . '_' . $reply->ID ) ) . "'>" . esc_html__( 'Restore', 'bbpress' ) . "</a>"; 749 749 } elseif ( EMPTY_TRASH_DAYS ) { 750 $actions['trash'] = "<a class='submitdelete' title='" . esc_attr__( 'Move this item to the Trash', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_reply_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $reply->ID ) ) . "'>" . __( 'Trash', 'bbpress' ) . "</a>";750 $actions['trash'] = "<a class='submitdelete' title='" . esc_attr__( 'Move this item to the Trash', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_reply_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $reply->ID ) ) . "'>" . esc_html__( 'Trash', 'bbpress' ) . "</a>"; 751 751 } 752 752 753 753 if ( bbp_get_trash_status_id() == $reply->post_status || !EMPTY_TRASH_DAYS ) { 754 $actions['delete'] = "<a class='submitdelete' title='" . esc_attr__( 'Delete this item permanently', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_reply_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $reply->ID, '', true ) ) . "'>" . __( 'Delete Permanently', 'bbpress' ) . "</a>";754 $actions['delete'] = "<a class='submitdelete' title='" . esc_attr__( 'Delete this item permanently', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_reply_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $reply->ID, '', true ) ) . "'>" . esc_html__( 'Delete Permanently', 'bbpress' ) . "</a>"; 755 755 } elseif ( bbp_get_spam_status_id() == $reply->post_status ) { 756 756 unset( $actions['trash'] ); -
trunk/includes/admin/settings.php
r4944 r4950 21 21 function bbp_admin_get_settings_sections() { 22 22 return (array) apply_filters( 'bbp_admin_get_settings_sections', array( 23 24 //25 23 'bbp_settings_main' => array( 26 24 'title' => __( 'Main Forum Settings', 'bbpress' ), … … 428 426 ?> 429 427 430 <p><?php _e( 'Main forum settings for enabling features and setting time limits', 'bbpress' ); ?></p>428 <p><?php esc_html_e( 'Main forum settings for enabling features and setting time limits', 'bbpress' ); ?></p> 431 429 432 430 <?php … … 444 442 445 443 <input name="_bbp_edit_lock" type="number" min="0" step="1" id="_bbp_edit_lock" value="<?php bbp_form_option( '_bbp_edit_lock', '5' ); ?>" class="small-text"<?php bbp_maybe_admin_setting_disabled( '_bbp_edit_lock' ); ?> /> 446 <label for="_bbp_edit_lock"><?php _e( 'minutes', 'bbpress' ); ?></label>444 <label for="_bbp_edit_lock"><?php esc_html_e( 'minutes', 'bbpress' ); ?></label> 447 445 448 446 <?php … … 460 458 461 459 <input name="_bbp_throttle_time" type="number" min="0" step="1" id="_bbp_throttle_time" value="<?php bbp_form_option( '_bbp_throttle_time', '10' ); ?>" class="small-text"<?php bbp_maybe_admin_setting_disabled( '_bbp_throttle_time' ); ?> /> 462 <label for="_bbp_throttle_time"><?php _e( 'seconds', 'bbpress' ); ?></label>460 <label for="_bbp_throttle_time"><?php esc_html_e( 'seconds', 'bbpress' ); ?></label> 463 461 464 462 <?php … … 476 474 477 475 <input id="_bbp_enable_favorites" name="_bbp_enable_favorites" type="checkbox" id="_bbp_enable_favorites" value="1" <?php checked( bbp_is_favorites_active( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_enable_favorites' ); ?> /> 478 <label for="_bbp_enable_favorites"><?php _e( 'Allow users to mark topics as favorites', 'bbpress' ); ?></label>476 <label for="_bbp_enable_favorites"><?php esc_html_e( 'Allow users to mark topics as favorites', 'bbpress' ); ?></label> 479 477 480 478 <?php … … 492 490 493 491 <input id="_bbp_enable_subscriptions" name="_bbp_enable_subscriptions" type="checkbox" id="_bbp_enable_subscriptions" value="1" <?php checked( bbp_is_subscriptions_active( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_enable_subscriptions' ); ?> /> 494 <label for="_bbp_enable_subscriptions"><?php _e( 'Allow users to subscribe to topics', 'bbpress' ); ?></label>492 <label for="_bbp_enable_subscriptions"><?php esc_html_e( 'Allow users to subscribe to topics', 'bbpress' ); ?></label> 495 493 496 494 <?php … … 508 506 509 507 <input id="_bbp_allow_topic_tags" name="_bbp_allow_topic_tags" type="checkbox" id="_bbp_allow_topic_tags" value="1" <?php checked( bbp_allow_topic_tags( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_allow_topic_tags' ); ?> /> 510 <label for="_bbp_allow_topic_tags"><?php _e( 'Allow topics to have tags', 'bbpress' ); ?></label>508 <label for="_bbp_allow_topic_tags"><?php esc_html_e( 'Allow topics to have tags', 'bbpress' ); ?></label> 511 509 512 510 <?php … … 538 536 </select> 539 537 540 <label for="_bbp_thread_replies_depth"><?php _e( 'levels deep', 'bbpress' ); ?></label>538 <label for="_bbp_thread_replies_depth"><?php esc_html_e( 'levels deep', 'bbpress' ); ?></label> 541 539 542 540 <?php … … 554 552 555 553 <input id="_bbp_allow_revisions" name="_bbp_allow_revisions" type="checkbox" id="_bbp_allow_revisions" value="1" <?php checked( bbp_allow_revisions( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_allow_revisions' ); ?> /> 556 <label for="_bbp_allow_revisions"><?php _e( 'Allow topic and reply revision logging', 'bbpress' ); ?></label>554 <label for="_bbp_allow_revisions"><?php esc_html_e( 'Allow topic and reply revision logging', 'bbpress' ); ?></label> 557 555 558 556 <?php … … 570 568 571 569 <input id="_bbp_allow_anonymous" name="_bbp_allow_anonymous" type="checkbox" id="_bbp_allow_anonymous" value="1" <?php checked( bbp_allow_anonymous( false ) ); bbp_maybe_admin_setting_disabled( '_bbp_allow_anonymous' ); ?> /> 572 <label for="_bbp_allow_anonymous"><?php _e( 'Allow guest users without accounts to create topics and replies', 'bbpress' ); ?></label>570 <label for="_bbp_allow_anonymous"><?php esc_html_e( 'Allow guest users without accounts to create topics and replies', 'bbpress' ); ?></label> 573 571 574 572 <?php … … 586 584 587 585 <input id="_bbp_allow_global_access" name="_bbp_allow_global_access" type="checkbox" id="_bbp_allow_global_access" value="1" <?php checked( bbp_allow_global_access( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_allow_global_access' ); ?> /> 588 <label for="_bbp_allow_global_access"><?php _e( 'Automatically assign default role to new, registered users upon visiting the site.', 'bbpress' ); ?></label>586 <label for="_bbp_allow_global_access"><?php esc_html_e( 'Automatically assign default role to new, registered users upon visiting the site.', 'bbpress' ); ?></label> 589 587 590 588 <?php … … 624 622 625 623 <input id="_bbp_use_wp_editor" name="_bbp_use_wp_editor" type="checkbox" id="_bbp_use_wp_editor" value="1" <?php checked( bbp_use_wp_editor( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_use_wp_editor' ); ?> /> 626 <label for="_bbp_use_wp_editor"><?php _e( 'Use the fancy WordPress editor to create and edit topics and replies', 'bbpress' ); ?></label>624 <label for="_bbp_use_wp_editor"><?php esc_html_e( 'Use the fancy WordPress editor to create and edit topics and replies', 'bbpress' ); ?></label> 627 625 628 626 <?php … … 637 635 ?> 638 636 639 <p><?php _e( 'How your forum content is displayed within your existing theme.', 'bbpress' ); ?></p>637 <p><?php esc_html_e( 'How your forum content is displayed within your existing theme.', 'bbpress' ); ?></p> 640 638 641 639 <?php … … 661 659 // @see bbPress::register_theme_packages() 662 660 foreach ( (array) bbpress()->theme_compat->packages as $id => $theme ) { 663 $theme_options .= '<option value="' . esc_attr( $id ) . '"' . selected( $theme->id, $current_package, false ) . '>' . sprintf( __( '%1$s - %2$s', 'bbpress' ), esc_html( $theme->name ), esc_html( str_replace( WP_CONTENT_DIR, '', $theme->dir ) ) ) . '</option>';661 $theme_options .= '<option value="' . esc_attr( $id ) . '"' . selected( $theme->id, $current_package, false ) . '>' . sprintf( esc_html__( '%1$s - %2$s', 'bbpress' ), esc_html( $theme->name ), esc_html( str_replace( WP_CONTENT_DIR, '', $theme->dir ) ) ) . '</option>'; 664 662 } 665 663 … … 667 665 668 666 <select name="_bbp_theme_package_id" id="_bbp_theme_package_id" <?php bbp_maybe_admin_setting_disabled( '_bbp_theme_package_id' ); ?>><?php echo $theme_options ?></select> 669 <label for="_bbp_theme_package_id"><?php _e( 'will serve all bbPress templates', 'bbpress' ); ?></label>667 <label for="_bbp_theme_package_id"><?php esc_html_e( 'will serve all bbPress templates', 'bbpress' ); ?></label> 670 668 671 669 <?php else : ?> 672 670 673 <p><?php _e( 'No template packages available.', 'bbpress' ); ?></p>671 <p><?php esc_html_e( 'No template packages available.', 'bbpress' ); ?></p> 674 672 675 673 <?php endif; … … 687 685 688 686 <input id="_bbp_use_autoembed" name="_bbp_use_autoembed" type="checkbox" id="_bbp_use_autoembed" value="1" <?php checked( bbp_use_autoembed( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_use_autoembed' ); ?> /> 689 <label for="_bbp_use_autoembed"><?php _e( 'Embed media (YouTube, Twitter, Flickr, etc...) directly into topics and replies', 'bbpress' ); ?></label>687 <label for="_bbp_use_autoembed"><?php esc_html_e( 'Embed media (YouTube, Twitter, Flickr, etc...) directly into topics and replies', 'bbpress' ); ?></label> 690 688 691 689 <?php … … 702 700 ?> 703 701 704 <p><?php _e( 'How many topics and replies to show per page', 'bbpress' ); ?></p>702 <p><?php esc_html_e( 'How many topics and replies to show per page', 'bbpress' ); ?></p> 705 703 706 704 <?php … … 718 716 719 717 <input name="_bbp_topics_per_page" type="number" min="1" step="1" id="_bbp_topics_per_page" value="<?php bbp_form_option( '_bbp_topics_per_page', '15' ); ?>" class="small-text"<?php bbp_maybe_admin_setting_disabled( '_bbp_topics_per_page' ); ?> /> 720 <label for="_bbp_topics_per_page"><?php _e( 'per page', 'bbpress' ); ?></label>718 <label for="_bbp_topics_per_page"><?php esc_html_e( 'per page', 'bbpress' ); ?></label> 721 719 722 720 <?php … … 734 732 735 733 <input name="_bbp_replies_per_page" type="number" min="1" step="1" id="_bbp_replies_per_page" value="<?php bbp_form_option( '_bbp_replies_per_page', '15' ); ?>" class="small-text"<?php bbp_maybe_admin_setting_disabled( '_bbp_replies_per_page' ); ?> /> 736 <label for="_bbp_replies_per_page"><?php _e( 'per page', 'bbpress' ); ?></label>734 <label for="_bbp_replies_per_page"><?php esc_html_e( 'per page', 'bbpress' ); ?></label> 737 735 738 736 <?php … … 749 747 ?> 750 748 751 <p><?php _e( 'How many topics and replies to show per RSS page', 'bbpress' ); ?></p>749 <p><?php esc_html_e( 'How many topics and replies to show per RSS page', 'bbpress' ); ?></p> 752 750 753 751 <?php … … 765 763 766 764 <input name="_bbp_topics_per_rss_page" type="number" min="1" step="1" id="_bbp_topics_per_rss_page" value="<?php bbp_form_option( '_bbp_topics_per_rss_page', '25' ); ?>" class="small-text"<?php bbp_maybe_admin_setting_disabled( '_bbp_topics_per_rss_page' ); ?> /> 767 <label for="_bbp_topics_per_rss_page"><?php _e( 'per page', 'bbpress' ); ?></label>765 <label for="_bbp_topics_per_rss_page"><?php esc_html_e( 'per page', 'bbpress' ); ?></label> 768 766 769 767 <?php … … 781 779 782 780 <input name="_bbp_replies_per_rss_page" type="number" min="1" step="1" id="_bbp_replies_per_rss_page" value="<?php bbp_form_option( '_bbp_replies_per_rss_page', '25' ); ?>" class="small-text"<?php bbp_maybe_admin_setting_disabled( '_bbp_replies_per_rss_page' ); ?> /> 783 <label for="_bbp_replies_per_rss_page"><?php _e( 'per page', 'bbpress' ); ?></label>781 <label for="_bbp_replies_per_rss_page"><?php esc_html_e( 'per page', 'bbpress' ); ?></label> 784 782 785 783 <?php … … 799 797 flush_rewrite_rules(); ?> 800 798 801 <p><?php _e( 'Customize your Forums root. Partner with a WordPress Page and use Shortcodes for more flexibility.', 'bbpress' ); ?></p>799 <p><?php esc_html_e( 'Customize your Forums root. Partner with a WordPress Page and use Shortcodes for more flexibility.', 'bbpress' ); ?></p> 802 800 803 801 <?php … … 832 830 833 831 <input id="_bbp_include_root" name="_bbp_include_root" type="checkbox" id="_bbp_include_root" value="1" <?php checked( bbp_include_root_slug() ); bbp_maybe_admin_setting_disabled( '_bbp_include_root' ); ?> /> 834 <label for="_bbp_include_root"><?php _e( 'Prefix all forum content with the Forum Root slug (Recommended)', 'bbpress' ); ?></label>832 <label for="_bbp_include_root"><?php esc_html_e( 'Prefix all forum content with the Forum Root slug (Recommended)', 'bbpress' ); ?></label> 835 833 836 834 <?php … … 882 880 ?> 883 881 884 <p><?php _e( 'Customize your user profile slugs.', 'bbpress' ); ?></p>882 <p><?php esc_html_e( 'Customize your user profile slugs.', 'bbpress' ); ?></p> 885 883 886 884 <?php … … 982 980 ?> 983 981 984 <p><?php printf( __( 'Custom slugs for single forums, topics, replies, tags, views, and search.', 'bbpress' ), get_admin_url( null, 'options-permalink.php' ) ); ?></p>982 <p><?php printf( esc_html__( 'Custom slugs for single forums, topics, replies, tags, views, and search.', 'bbpress' ), get_admin_url( null, 'options-permalink.php' ) ); ?></p> 985 983 986 984 <?php … … 1100 1098 ?> 1101 1099 1102 <p><?php _e( 'Forum settings for BuddyPress', 'bbpress' ); ?></p>1100 <p><?php esc_html_e( 'Forum settings for BuddyPress', 'bbpress' ); ?></p> 1103 1101 1104 1102 <?php … … 1116 1114 1117 1115 <input id="_bbp_enable_group_forums" name="_bbp_enable_group_forums" type="checkbox" id="_bbp_enable_group_forums" value="1" <?php checked( bbp_is_group_forums_active( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_enable_group_forums' ); ?> /> 1118 <label for="_bbp_enable_group_forums"><?php _e( 'Allow BuddyPress Groups to have their own forums', 'bbpress' ); ?></label>1116 <label for="_bbp_enable_group_forums"><?php esc_html_e( 'Allow BuddyPress Groups to have their own forums', 'bbpress' ); ?></label> 1119 1117 1120 1118 <?php … … 1141 1139 ) ); ?> 1142 1140 1143 <label for="_bbp_group_forums_root_id"><?php _e( 'is the parent for all group forums', 'bbpress' ); ?></label>1144 <p class="description"><?php _e( 'Using the Forum Root is not recommended. Changing this does not move existing forums.', 'bbpress' ); ?></p>1141 <label for="_bbp_group_forums_root_id"><?php esc_html_e( 'is the parent for all group forums', 'bbpress' ); ?></label> 1142 <p class="description"><?php esc_html_e( 'Using the Forum Root is not recommended. Changing this does not move existing forums.', 'bbpress' ); ?></p> 1145 1143 1146 1144 <?php … … 1157 1155 ?> 1158 1156 1159 <p><?php _e( 'Forum settings for Akismet', 'bbpress' ); ?></p>1157 <p><?php esc_html_e( 'Forum settings for Akismet', 'bbpress' ); ?></p> 1160 1158 1161 1159 <?php … … 1174 1172 1175 1173 <input id="_bbp_enable_akismet" name="_bbp_enable_akismet" type="checkbox" id="_bbp_enable_akismet" value="1" <?php checked( bbp_is_akismet_active( true ) ); bbp_maybe_admin_setting_disabled( '_bbp_enable_akismet' ); ?> /> 1176 <label for="_bbp_enable_akismet"><?php _e( 'Allow Akismet to actively prevent forum spam.', 'bbpress' ); ?></label>1174 <label for="_bbp_enable_akismet"><?php esc_html_e( 'Allow Akismet to actively prevent forum spam.', 'bbpress' ); ?></label> 1177 1175 1178 1176 <?php … … 1197 1195 <?php screen_icon(); ?> 1198 1196 1199 <h2><?php _e( 'Forums Settings', 'bbpress' ) ?></h2>1197 <h2><?php esc_html_e( 'Forums Settings', 'bbpress' ) ?></h2> 1200 1198 1201 1199 <form action="options.php" method="post"> … … 1225 1223 ?> 1226 1224 1227 <p><?php _e( 'Information about your previous forums database so that they can be converted. <strong>Backup your database before proceeding.</strong>', 'bbpress' ); ?></p>1225 <p><?php esc_html_e( 'Information about your previous forums database so that they can be converted. <strong>Backup your database before proceeding.</strong>', 'bbpress' ); ?></p> 1228 1226 1229 1227 <?php … … 1248 1246 if ( ( stristr( $file, '.php' ) ) && ( stristr( $file, 'index' ) === false ) ) { 1249 1247 $file = preg_replace( '/.php/', '', $file ); 1250 $platform_options .= '<option value="' . $file . '">' . $file. '</option>';1248 $platform_options .= '<option value="' . $file . '">' . esc_html( $file ) . '</option>'; 1251 1249 } 1252 1250 } … … 1255 1253 1256 1254 <select name="_bbp_converter_platform" id="_bbp_converter_platform" /><?php echo $platform_options ?></select> 1257 <label for="_bbp_converter_platform"><?php _e( 'is the previous forum software', 'bbpress' ); ?></label>1255 <label for="_bbp_converter_platform"><?php esc_html_e( 'is the previous forum software', 'bbpress' ); ?></label> 1258 1256 1259 1257 <?php … … 1269 1267 1270 1268 <input name="_bbp_converter_db_server" type="text" id="_bbp_converter_db_server" value="<?php bbp_form_option( '_bbp_converter_db_server', 'localhost' ); ?>" class="medium-text" /> 1271 <label for="_bbp_converter_db_server"><?php _e( 'IP or hostname', 'bbpress' ); ?></label>1269 <label for="_bbp_converter_db_server"><?php esc_html_e( 'IP or hostname', 'bbpress' ); ?></label> 1272 1270 1273 1271 <?php … … 1283 1281 1284 1282 <input name="_bbp_converter_db_port" type="text" id="_bbp_converter_db_port" value="<?php bbp_form_option( '_bbp_converter_db_port', '3306' ); ?>" class="small-text" /> 1285 <label for="_bbp_converter_db_port"><?php _e( 'Use default 3306 if unsure', 'bbpress' ); ?></label>1283 <label for="_bbp_converter_db_port"><?php esc_html_e( 'Use default 3306 if unsure', 'bbpress' ); ?></label> 1286 1284 1287 1285 <?php … … 1297 1295 1298 1296 <input name="_bbp_converter_db_user" type="text" id="_bbp_converter_db_user" value="<?php bbp_form_option( '_bbp_converter_db_user' ); ?>" class="medium-text" /> 1299 <label for="_bbp_converter_db_user"><?php _e( 'User for your database connection', 'bbpress' ); ?></label>1297 <label for="_bbp_converter_db_user"><?php esc_html_e( 'User for your database connection', 'bbpress' ); ?></label> 1300 1298 1301 1299 <?php … … 1311 1309 1312 1310 <input name="_bbp_converter_db_pass" type="password" id="_bbp_converter_db_pass" value="<?php bbp_form_option( '_bbp_converter_db_pass' ); ?>" class="medium-text" /> 1313 <label for="_bbp_converter_db_pass"><?php _e( 'Password to access the database', 'bbpress' ); ?></label>1311 <label for="_bbp_converter_db_pass"><?php esc_html_e( 'Password to access the database', 'bbpress' ); ?></label> 1314 1312 1315 1313 <?php … … 1325 1323 1326 1324 <input name="_bbp_converter_db_name" type="text" id="_bbp_converter_db_name" value="<?php bbp_form_option( '_bbp_converter_db_name' ); ?>" class="medium-text" /> 1327 <label for="_bbp_converter_db_name"><?php _e( 'Name of the database with your old forum data', 'bbpress' ); ?></label>1325 <label for="_bbp_converter_db_name"><?php esc_html_e( 'Name of the database with your old forum data', 'bbpress' ); ?></label> 1328 1326 1329 1327 <?php … … 1338 1336 ?> 1339 1337 1340 <p><?php _e( 'Some optional parameters to help tune the conversion process.', 'bbpress' ); ?></p>1338 <p><?php esc_html_e( 'Some optional parameters to help tune the conversion process.', 'bbpress' ); ?></p> 1341 1339 1342 1340 <?php … … 1352 1350 1353 1351 <input name="_bbp_converter_db_prefix" type="text" id="_bbp_converter_db_prefix" value="<?php bbp_form_option( '_bbp_converter_db_prefix' ); ?>" class="medium-text" /> 1354 <label for="_bbp_converter_db_prefix"><?php _e( '(If converting from BuddyPress Forums, use "wp_bb_" or your custom prefix)', 'bbpress' ); ?></label>1352 <label for="_bbp_converter_db_prefix"><?php esc_html_e( '(If converting from BuddyPress Forums, use "wp_bb_" or your custom prefix)', 'bbpress' ); ?></label> 1355 1353 1356 1354 <?php … … 1366 1364 1367 1365 <input name="_bbp_converter_rows" type="text" id="_bbp_converter_rows" value="<?php bbp_form_option( '_bbp_converter_rows', '100' ); ?>" class="small-text" /> 1368 <label for="_bbp_converter_rows"><?php _e( 'rows to process at a time', 'bbpress' ); ?></label>1369 <p class="description"><?php _e( 'Keep this low if you experience out-of-memory issues.', 'bbpress' ); ?></p>1366 <label for="_bbp_converter_rows"><?php esc_html_e( 'rows to process at a time', 'bbpress' ); ?></label> 1367 <p class="description"><?php esc_html_e( 'Keep this low if you experience out-of-memory issues.', 'bbpress' ); ?></p> 1370 1368 1371 1369 <?php … … 1381 1379 1382 1380 <input name="_bbp_converter_delay_time" type="text" id="_bbp_converter_delay_time" value="<?php bbp_form_option( '_bbp_converter_delay_time', '1' ); ?>" class="small-text" /> 1383 <label for="_bbp_converter_delay_time"><?php _e( 'second(s) delay between each group of rows', 'bbpress' ); ?></label>1384 <p class="description"><?php _e( 'Keep this high to prevent too-many-connection issues.', 'bbpress' ); ?></p>1381 <label for="_bbp_converter_delay_time"><?php esc_html_e( 'second(s) delay between each group of rows', 'bbpress' ); ?></label> 1382 <p class="description"><?php esc_html_e( 'Keep this high to prevent too-many-connection issues.', 'bbpress' ); ?></p> 1385 1383 1386 1384 <?php … … 1396 1394 1397 1395 <input id="_bbp_converter_restart" name="_bbp_converter_restart" type="checkbox" id="_bbp_converter_restart" value="1" <?php checked( get_option( '_bbp_converter_restart', false ) ); ?> /> 1398 <label for="_bbp_converter_restart"><?php _e( 'Start a fresh conversion from the beginning', 'bbpress' ); ?></label>1399 <p class="description"><?php _e( 'You should clean old conversion information before starting over.', 'bbpress' ); ?></p>1396 <label for="_bbp_converter_restart"><?php esc_html_e( 'Start a fresh conversion from the beginning', 'bbpress' ); ?></label> 1397 <p class="description"><?php esc_html_e( 'You should clean old conversion information before starting over.', 'bbpress' ); ?></p> 1400 1398 1401 1399 <?php … … 1411 1409 1412 1410 <input id="_bbp_converter_clean" name="_bbp_converter_clean" type="checkbox" id="_bbp_converter_clean" value="1" <?php checked( get_option( '_bbp_converter_clean', false ) ); ?> /> 1413 <label for="_bbp_converter_clean"><?php _e( 'Purge all information from a previously attempted import', 'bbpress' ); ?></label>1414 <p class="description"><?php _e( 'Use this if an import failed and you want to remove that incomplete data.', 'bbpress' ); ?></p>1411 <label for="_bbp_converter_clean"><?php esc_html_e( 'Purge all information from a previously attempted import', 'bbpress' ); ?></label> 1412 <p class="description"><?php esc_html_e( 'Use this if an import failed and you want to remove that incomplete data.', 'bbpress' ); ?></p> 1415 1413 1416 1414 <?php … … 1426 1424 1427 1425 <input id="_bbp_converter_convert_users" name="_bbp_converter_convert_users" type="checkbox" id="_bbp_converter_convert_users" value="1" <?php checked( get_option( '_bbp_converter_convert_users', false ) ); ?> /> 1428 <label for="_bbp_converter_convert_users"><?php _e( 'Attempt to import user accounts from previous forums', 'bbpress' ); ?></label>1429 <p class="description"><?php _e( 'Non-bbPress passwords cannot be automatically converted. They will be converted as each user logs in.', 'bbpress' ); ?></p>1426 <label for="_bbp_converter_convert_users"><?php esc_html_e( 'Attempt to import user accounts from previous forums', 'bbpress' ); ?></label> 1427 <p class="description"><?php esc_html_e( 'Non-bbPress passwords cannot be automatically converted. They will be converted as each user logs in.', 'bbpress' ); ?></p> 1430 1428 1431 1429 <?php … … 1448 1446 <?php screen_icon( 'tools' ); ?> 1449 1447 1450 <h2 class="nav-tab-wrapper"><?php bbp_tools_admin_tabs( __( 'Import Forums', 'bbpress' ) ); ?></h2>1448 <h2 class="nav-tab-wrapper"><?php bbp_tools_admin_tabs( esc_html__( 'Import Forums', 'bbpress' ) ); ?></h2> 1451 1449 1452 1450 <form action="#" method="post" id="bbp-converter-settings"> … … 1694 1692 if ( ( $slug != $key ) && ( $slug_check == $this_slug ) ) : ?> 1695 1693 1696 <span class="attention"><?php printf( __( 'Possible %1$s conflict: <strong>%2$s</strong>', 'bbpress' ), $value['context'], $value['name']); ?></span>1694 <span class="attention"><?php printf( esc_html__( 'Possible %1$s conflict: %2$s', 'bbpress' ), $value['context'], '<strong>' . $value['name'] . '</strong>' ); ?></span> 1697 1695 1698 1696 <?php endif; -
trunk/includes/admin/tools.php
r4899 r4950 34 34 <h2 class="nav-tab-wrapper"><?php bbp_tools_admin_tabs( __( 'Repair Forums', 'bbpress' ) ); ?></h2> 35 35 36 <p><?php _e( 'bbPress keeps track of relationships between forums, topics, replies, and topic tags, and users. Occasionally these relationships become out of sync, most often after an import or migration. Use the tools below to manually recalculate these relationships.', 'bbpress' ); ?></p>37 <p class="description"><?php _e( 'Some of these tools create substantial database overhead. Avoid running more than 1 repair job at a time.', 'bbpress' ); ?></p>36 <p><?php esc_html_e( 'bbPress keeps track of relationships between forums, topics, replies, and topic tags, and users. Occasionally these relationships become out of sync, most often after an import or migration. Use the tools below to manually recalculate these relationships.', 'bbpress' ); ?></p> 37 <p class="description"><?php esc_html_e( 'Some of these tools create substantial database overhead. Avoid running more than 1 repair job at a time.', 'bbpress' ); ?></p> 38 38 39 39 <form class="settings" method="post" action=""> … … 41 41 <tbody> 42 42 <tr valign="top"> 43 <th scope="row"><?php _e( 'Relationships to Repair:', 'bbpress' ) ?></th>43 <th scope="row"><?php esc_html_e( 'Relationships to Repair:', 'bbpress' ) ?></th> 44 44 <td> 45 45 <fieldset> 46 <legend class="screen-reader-text"><span><?php _e( 'Repair', 'bbpress' ) ?></span></legend>46 <legend class="screen-reader-text"><span><?php esc_html_e( 'Repair', 'bbpress' ) ?></span></legend> 47 47 48 48 <?php foreach ( bbp_admin_repair_list() as $item ) : ?> … … 1095 1095 1096 1096 <h2 class="nav-tab-wrapper"><?php bbp_tools_admin_tabs( __( 'Reset Forums', 'bbpress' ) ); ?></h2> 1097 <p><?php _e( 'This will revert your forums back to a brand new installation. This process cannot be undone. <strong>Backup your database before proceeding</strong>.', 'bbpress' ); ?></p>1097 <p><?php esc_html_e( 'This will revert your forums back to a brand new installation. This process cannot be undone. <strong>Backup your database before proceeding</strong>.', 'bbpress' ); ?></p> 1098 1098 1099 1099 <form class="settings" method="post" action=""> … … 1101 1101 <tbody> 1102 1102 <tr valign="top"> 1103 <th scope="row"><?php _e( 'The following data will be removed:', 'bbpress' ) ?></th>1103 <th scope="row"><?php esc_html_e( 'The following data will be removed:', 'bbpress' ) ?></th> 1104 1104 <td> 1105 <?php _e( 'All Forums', 'bbpress' ); ?><br />1106 <?php _e( 'All Topics', 'bbpress' ); ?><br />1107 <?php _e( 'All Replies', 'bbpress' ); ?><br />1108 <?php _e( 'All Topic Tags', 'bbpress' ); ?><br />1109 <?php _e( 'Related Meta Data', 'bbpress' ); ?><br />1110 <?php _e( 'Forum Settings', 'bbpress' ); ?><br />1111 <?php _e( 'Forum Activity', 'bbpress' ); ?><br />1112 <?php _e( 'Forum User Roles', 'bbpress' ); ?><br />1113 <?php _e( 'Importer Helper Data', 'bbpress' ); ?><br />1105 <?php esc_html_e( 'All Forums', 'bbpress' ); ?><br /> 1106 <?php esc_html_e( 'All Topics', 'bbpress' ); ?><br /> 1107 <?php esc_html_e( 'All Replies', 'bbpress' ); ?><br /> 1108 <?php esc_html_e( 'All Topic Tags', 'bbpress' ); ?><br /> 1109 <?php esc_html_e( 'Related Meta Data', 'bbpress' ); ?><br /> 1110 <?php esc_html_e( 'Forum Settings', 'bbpress' ); ?><br /> 1111 <?php esc_html_e( 'Forum Activity', 'bbpress' ); ?><br /> 1112 <?php esc_html_e( 'Forum User Roles', 'bbpress' ); ?><br /> 1113 <?php esc_html_e( 'Importer Helper Data', 'bbpress' ); ?><br /> 1114 1114 </td> 1115 1115 </tr> 1116 1116 <tr valign="top"> 1117 <th scope="row"><?php _e( 'Are you sure you want to do this?', 'bbpress' ) ?></th>1117 <th scope="row"><?php esc_html_e( 'Are you sure you want to do this?', 'bbpress' ) ?></th> 1118 1118 <td> 1119 1119 <fieldset> 1120 <legend class="screen-reader-text"><span><?php _e( "Say it ain't so!", 'bbpress' ) ?></span></legend>1121 <label><input type="checkbox" class="checkbox" name="bbpress-are-you-sure" id="bbpress-are-you-sure" value="1" /> <?php _e( 'This process cannot be undone.', 'bbpress' ); ?></label>1120 <legend class="screen-reader-text"><span><?php esc_html_e( "Say it ain't so!", 'bbpress' ) ?></span></legend> 1121 <label><input type="checkbox" class="checkbox" name="bbpress-are-you-sure" id="bbpress-are-you-sure" value="1" /> <?php esc_html_e( 'This process cannot be undone.', 'bbpress' ); ?></label> 1122 1122 </fieldset> 1123 1123 </td> -
trunk/includes/admin/topics.php
r4909 r4950 569 569 return; 570 570 571 $topic_title = esc_html( bbp_get_topic_title( $topic->ID ));571 $topic_title = bbp_get_topic_title( $topic->ID ); 572 572 573 573 switch ( $notice ) { … … 607 607 608 608 <div id="message" class="<?php echo $is_failure == true ? 'error' : 'updated'; ?> fade"> 609 <p style="line-height: 150%"><?php echo $message; ?></p>609 <p style="line-height: 150%"><?php echo esc_html( $message ); ?></p> 610 610 </div> 611 611 … … 686 686 $forum_title = bbp_get_forum_title( $forum_id ); 687 687 if ( empty( $forum_title ) ) { 688 $forum_title = __( 'No Forum', 'bbpress' );688 $forum_title = esc_html__( 'No Forum', 'bbpress' ); 689 689 } 690 690 … … 693 693 694 694 } else { 695 _e( '(No Forum)', 'bbpress' );695 esc_html_e( '(No Forum)', 'bbpress' ); 696 696 } 697 697 … … 715 715 // Freshness 716 716 case 'bbp_topic_created': 717 printf( __( '%1$s <br /> %2$s', 'bbpress' ),717 printf( '%1$s <br /> %2$s', 718 718 get_the_date(), 719 719 esc_attr( get_the_time() ) … … 726 726 $last_active = bbp_get_topic_last_active_time( $topic_id, false ); 727 727 if ( !empty( $last_active ) ) { 728 echo $last_active;728 echo esc_html( $last_active ); 729 729 } else { 730 _e( 'No Replies', 'bbpress' ); // This should never happen730 esc_html_e( 'No Replies', 'bbpress' ); // This should never happen 731 731 } 732 732 … … 775 775 // Show view link if it's not set, the topic is trashed and the user can view trashed topics 776 776 if ( empty( $actions['view'] ) && ( bbp_get_trash_status_id() == $topic->post_status ) && current_user_can( 'view_trash' ) ) 777 $actions['view'] = '<a href="' . bbp_get_topic_permalink( $topic->ID ) . '" title="' . esc_attr( sprintf( __( 'View “%s”', 'bbpress' ), bbp_get_topic_title( $topic->ID ) ) ) . '" rel="permalink">' . __( 'View', 'bbpress' ) . '</a>';777 $actions['view'] = '<a href="' . bbp_get_topic_permalink( $topic->ID ) . '" title="' . esc_attr( sprintf( __( 'View “%s”', 'bbpress' ), bbp_get_topic_title( $topic->ID ) ) ) . '" rel="permalink">' . esc_html__( 'View', 'bbpress' ) . '</a>'; 778 778 779 779 // Only show the actions if the user is capable of viewing them :) … … 783 783 // Show the 'close' and 'open' link on published and closed posts only 784 784 if ( in_array( $topic->post_status, array( bbp_get_public_status_id(), bbp_get_closed_status_id() ) ) ) { 785 $close_uri = esc_url( wp_nonce_url( add_query_arg( array( 'topic_id' => $topic->ID, 'action' => 'bbp_toggle_topic_close' ), remove_query_arg( array( 'bbp_topic_toggle_notice', 'topic_id', 'failed', 'super' ) ) ), 'close-topic_' . $topic->ID ));785 $close_uri = wp_nonce_url( add_query_arg( array( 'topic_id' => $topic->ID, 'action' => 'bbp_toggle_topic_close' ), remove_query_arg( array( 'bbp_topic_toggle_notice', 'topic_id', 'failed', 'super' ) ) ), 'close-topic_' . $topic->ID ); 786 786 if ( bbp_is_topic_open( $topic->ID ) ) 787 $actions['closed'] = '<a href="' . $close_uri. '" title="' . esc_attr__( 'Close this topic', 'bbpress' ) . '">' . _x( 'Close', 'Close a Topic', 'bbpress' ) . '</a>';787 $actions['closed'] = '<a href="' . esc_url( $close_uri ) . '" title="' . esc_attr__( 'Close this topic', 'bbpress' ) . '">' . _x( 'Close', 'Close a Topic', 'bbpress' ) . '</a>'; 788 788 else 789 $actions['closed'] = '<a href="' . $close_uri. '" title="' . esc_attr__( 'Open this topic', 'bbpress' ) . '">' . _x( 'Open', 'Open a Topic', 'bbpress' ) . '</a>';789 $actions['closed'] = '<a href="' . esc_url( $close_uri ) . '" title="' . esc_attr__( 'Open this topic', 'bbpress' ) . '">' . _x( 'Open', 'Open a Topic', 'bbpress' ) . '</a>'; 790 790 } 791 791 … … 794 794 795 795 // Sticky 796 $stick_uri = esc_url( wp_nonce_url( add_query_arg( array( 'topic_id' => $topic->ID, 'action' => 'bbp_toggle_topic_stick' ), remove_query_arg( array( 'bbp_topic_toggle_notice', 'topic_id', 'failed', 'super' ) ) ), 'stick-topic_' . $topic->ID ));796 $stick_uri = wp_nonce_url( add_query_arg( array( 'topic_id' => $topic->ID, 'action' => 'bbp_toggle_topic_stick' ), remove_query_arg( array( 'bbp_topic_toggle_notice', 'topic_id', 'failed', 'super' ) ) ), 'stick-topic_' . $topic->ID ); 797 797 if ( bbp_is_topic_sticky( $topic->ID ) ) { 798 $actions['stick'] = '<a href="' . $stick_uri . '" title="' . esc_attr__( 'Unstick this topic', 'bbpress' ) . '">' .__( 'Unstick', 'bbpress' ) . '</a>';798 $actions['stick'] = '<a href="' . esc_url( $stick_uri ) . '" title="' . esc_attr__( 'Unstick this topic', 'bbpress' ) . '">' . esc_html__( 'Unstick', 'bbpress' ) . '</a>'; 799 799 } else { 800 800 $super_uri = esc_url( wp_nonce_url( add_query_arg( array( 'topic_id' => $topic->ID, 'action' => 'bbp_toggle_topic_stick', 'super' => '1' ), remove_query_arg( array( 'bbp_topic_toggle_notice', 'topic_id', 'failed', 'super' ) ) ), 'stick-topic_' . $topic->ID ) ); 801 $actions['stick'] = '<a href="' . $stick_uri . '" title="' . esc_attr__( 'Stick this topic to its forum', 'bbpress' ) . '">' . __( 'Stick', 'bbpress' ) . '</a> (<a href="' . $super_uri . '" title="' . esc_attr__( 'Stick this topic to front', 'bbpress' ) . '">' .__( 'to front', 'bbpress' ) . '</a>)';801 $actions['stick'] = '<a href="' . esc_url( $stick_uri ) . '" title="' . esc_attr__( 'Stick this topic to its forum', 'bbpress' ) . '">' . esc_html__( 'Stick', 'bbpress' ) . '</a> (<a href="' . $super_uri . '" title="' . esc_attr__( 'Stick this topic to front', 'bbpress' ) . '">' . esc_html__( 'to front', 'bbpress' ) . '</a>)'; 802 802 } 803 803 } 804 804 805 805 // Spam 806 $spam_uri = esc_url( wp_nonce_url( add_query_arg( array( 'topic_id' => $topic->ID, 'action' => 'bbp_toggle_topic_spam' ), remove_query_arg( array( 'bbp_topic_toggle_notice', 'topic_id', 'failed', 'super' ) ) ), 'spam-topic_' . $topic->ID ));806 $spam_uri = wp_nonce_url( add_query_arg( array( 'topic_id' => $topic->ID, 'action' => 'bbp_toggle_topic_spam' ), remove_query_arg( array( 'bbp_topic_toggle_notice', 'topic_id', 'failed', 'super' ) ) ), 'spam-topic_' . $topic->ID ); 807 807 if ( bbp_is_topic_spam( $topic->ID ) ) 808 $actions['spam'] = '<a href="' . $spam_uri . '" title="' . esc_attr__( 'Mark the topic as not spam', 'bbpress' ) . '">' .__( 'Not spam', 'bbpress' ) . '</a>';808 $actions['spam'] = '<a href="' . esc_url( $spam_uri ) . '" title="' . esc_attr__( 'Mark the topic as not spam', 'bbpress' ) . '">' . esc_html__( 'Not spam', 'bbpress' ) . '</a>'; 809 809 else 810 $actions['spam'] = '<a href="' . $spam_uri . '" title="' . esc_attr__( 'Mark this topic as spam', 'bbpress' ) . '">' .__( 'Spam', 'bbpress' ) . '</a>';810 $actions['spam'] = '<a href="' . esc_url( $spam_uri ) . '" title="' . esc_attr__( 'Mark this topic as spam', 'bbpress' ) . '">' . esc_html__( 'Spam', 'bbpress' ) . '</a>'; 811 811 812 812 } … … 816 816 if ( bbp_get_trash_status_id() == $topic->post_status ) { 817 817 $post_type_object = get_post_type_object( bbp_get_topic_post_type() ); 818 $actions['untrash'] = "<a title='" . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . "' href='" . wp_nonce_url( add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), admin_url( 'edit.php' ) ) ), admin_url( sprintf( $post_type_object->_edit_link . '&action=untrash', $topic->ID ) ) ), 'untrash-' . $topic->post_type . '_' . $topic->ID ) . "'>" . __( 'Restore', 'bbpress' ) . "</a>";818 $actions['untrash'] = "<a title='" . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . "' href='" . wp_nonce_url( add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), admin_url( 'edit.php' ) ) ), admin_url( sprintf( $post_type_object->_edit_link . '&action=untrash', $topic->ID ) ) ), 'untrash-' . $topic->post_type . '_' . $topic->ID ) . "'>" . esc_html__( 'Restore', 'bbpress' ) . "</a>"; 819 819 } elseif ( EMPTY_TRASH_DAYS ) { 820 $actions['trash'] = "<a class='submitdelete' title='" . esc_attr__( 'Move this item to the Trash', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $topic->ID ) ) . "'>" . __( 'Trash', 'bbpress' ) . "</a>";820 $actions['trash'] = "<a class='submitdelete' title='" . esc_attr__( 'Move this item to the Trash', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $topic->ID ) ) . "'>" . esc_html__( 'Trash', 'bbpress' ) . "</a>"; 821 821 } 822 822 823 823 if ( bbp_get_trash_status_id() == $topic->post_status || !EMPTY_TRASH_DAYS ) { 824 $actions['delete'] = "<a class='submitdelete' title='" . esc_attr__( 'Delete this item permanently', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $topic->ID, '', true ) ) . "'>" . __( 'Delete Permanently', 'bbpress' ) . "</a>";824 $actions['delete'] = "<a class='submitdelete' title='" . esc_attr__( 'Delete this item permanently', 'bbpress' ) . "' href='" . add_query_arg( array( '_wp_http_referer' => add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), admin_url( 'edit.php' ) ) ), get_delete_post_link( $topic->ID, '', true ) ) . "'>" . esc_html__( 'Delete Permanently', 'bbpress' ) . "</a>"; 825 825 } elseif ( bbp_get_spam_status_id() == $topic->post_status ) { 826 826 unset( $actions['trash'] ); -
trunk/includes/admin/users.php
r4783 r4950 80 80 unset( $dynamic_roles[ bbp_get_keymaster_role() ] ); ?> 81 81 82 <h3><?php _e( 'Forums', 'bbpress' ); ?></h3>82 <h3><?php esc_html_e( 'Forums', 'bbpress' ); ?></h3> 83 83 84 84 <table class="form-table"> 85 85 <tbody> 86 86 <tr> 87 <th><label for="bbp-forums-role"><?php _e( 'Forum Role', 'bbpress' ); ?></label></th>87 <th><label for="bbp-forums-role"><?php esc_html_e( 'Forum Role', 'bbpress' ); ?></label></th> 88 88 <td> 89 89 … … 94 94 <?php if ( ! empty( $user_role ) ) : ?> 95 95 96 <option value=""><?php _e( '— No role for these forums —', 'bbpress' ); ?></option>96 <option value=""><?php esc_html_e( '— No role for these forums —', 'bbpress' ); ?></option> 97 97 98 98 <?php else : ?> 99 99 100 <option value="" selected="selected"><?php _e( '— No role for these forums —', 'bbpress' ); ?></option>100 <option value="" selected="selected"><?php esc_html_e( '— No role for these forums —', 'bbpress' ); ?></option> 101 101 102 102 <?php endif; ?> … … 136 136 unset( $dynamic_roles[ bbp_get_keymaster_role() ] ); ?> 137 137 138 <label class="screen-reader-text" for="bbp-new-role"><?php _e( 'Change forum role to…', 'bbpress' ) ?></label>138 <label class="screen-reader-text" for="bbp-new-role"><?php esc_html_e( 'Change forum role to…', 'bbpress' ) ?></label> 139 139 <select name="bbp-new-role" id="bbp-new-role" style="display:inline-block; float:none;"> 140 <option value=''><?php _e( 'Change forum role to…', 'bbpress' ) ?></option>140 <option value=''><?php esc_html_e( 'Change forum role to…', 'bbpress' ) ?></option> 141 141 <?php foreach ( $dynamic_roles as $role => $details ) : ?> 142 142 <option value="<?php echo esc_attr( $role ); ?>"><?php echo translate_user_role( $details['name'] ); ?></option>
Note: See TracChangeset
for help on using the changeset viewer.