Changeset 8656 for trunk/wp-admin/press-this.php
- Timestamp:
- 08/16/2008 07:27:34 AM (18 years ago)
- File:
-
- 1 edited
-
trunk/wp-admin/press-this.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/press-this.php
r8600 r8656 1 1 <?php 2 /** 3 * Press This Display and Handler. 4 * 5 * @package WordPress 6 * @subpackage Press_This 7 */ 8 9 /** WordPress Administration Bootstrap */ 2 10 require_once('admin.php'); 3 11 4 12 if ( ! current_user_can('publish_posts') ) wp_die( __( 'Cheatin’ uh?' ) ); 5 13 14 /** 15 * Replace forward slash with backslash and slash. 16 * 17 * @package WordPress 18 * @subpackage Press_This 19 * @since unknown 20 * 21 * @param string $string 22 * @return string 23 */ 6 24 function preg_quote2($string) { 7 25 return str_replace('/', '\/', preg_quote($string)); 8 26 } 27 28 /** 29 * Convert characters. 30 * 31 * @package WordPress 32 * @subpackage Press_This 33 * @since unknown 34 * 35 * @param string $text 36 * @return string 37 */ 9 38 function aposfix($text) { 10 39 $translation_table[chr(34)] = '"'; … … 13 42 return preg_replace("/&(?![A-Za-z]{0,4}\w{2,3};|#[0-9]{2,3};)/","&" , strtr($text, $translation_table)); 14 43 } 44 45 /** 46 * Press It form handler. 47 * 48 * @package WordPress 49 * @subpackage Press_This 50 * @since unknown 51 * 52 * @return int Post ID 53 */ 15 54 function press_it() { 16 55 // define some basic variables
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)