Changeset 11530 for trunk/wp-admin/includes/misc.php
- Timestamp:
- 06/07/2009 01:52:44 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/misc.php
r11450 r11530 342 342 jQuery('#newcontent_cp').val(newcontent.getCode()).removeAttr('disabled'); 343 343 }); 344 jQuery('#codepress-on').hide(); 345 jQuery('#codepress-off').show(); 344 346 /* ]]> */ 345 347 </script> 346 348 <?php 349 } 350 351 /** 352 * Determine whether to use CodePress or not. 353 * 354 * @since 2.8 355 **/ 356 function use_codepress() { 357 358 if ( isset($_GET['codepress']) ) { 359 $on = 'on' == $_GET['codepress'] ? 'on' : 'off'; 360 set_user_setting( 'codepress', $on ); 361 } else { 362 $on = get_user_setting('codepress', 'on'); 363 } 364 365 if ( 'on' == $on ) { 366 add_action( 'admin_print_footer_scripts', 'codepress_footer_js' ); 367 return true; 368 } 369 370 return false; 347 371 } 348 372
Note: See TracChangeset
for help on using the changeset viewer.