Make WordPress Core

Changes from tags/2.2.2 at r6063 to tags/2.2.3 at r6063


Ignore:
Location:
tags/2.2.3
Files:
19 edited

Legend:

Unmodified
Added
Removed
  • tags/2.2.3/wp-admin/admin-ajax.php

    r6063 r6063  
    287287        }
    288288    }
    289     die($_POST['post_type']);
     289    die('0');
    290290break;
    291291default :
  • tags/2.2.3/wp-admin/admin-functions.php

    r6063 r6063  
    106106        $_POST['post_date_gmt'] = get_gmt_from_date( $_POST['post_date'] );
    107107    }
     108   
     109    unset($_POST['no_filter']);
    108110
    109111    // Create the post.
     
    284286    }
    285287
     288    unset($_POST['no_filter']);
     289   
    286290    add_meta( $post_ID );
    287291
  • tags/2.2.3/wp-admin/install-rtl.css

    r6063 r6063  
    1 body { font-family: Tahoma, Georgia, "Times New Roman", Times, serif; }
     1body { font: 13px Tahoma, Georgia, "Times New Roman", Times, serif; }
    22
    33ul, ol { padding: 5px 20px 5px 5px; }
    44
    5 .step, th { text-align: left; }
     5h1, h2, h3 { font-family: "Times New Roman", Times, serif; font-weight: 700 }
     6
     7.step, th { text-align: left }
     8
     9input { font-family: "Times New Roman", Times, serif; padding: 1px }
     10
     11#logo { background: url(../wp-content/plugins/WP-Jalali/wp-fa-logo.png) center right no-repeat; text-align: left; }
     12
     13#admin_email {direction: ltr; text-align: left; }
     14
     15#footer { font-style: normal; }
  • tags/2.2.3/wp-admin/options.php

    r6063 r6063  
    1010if ( !current_user_can('manage_options') )
    1111    wp_die(__('Cheatin’ uh?'));
    12 
    13 function sanitize_option($option, $value) { // Remember to call stripslashes!
    14 
    15     switch ($option) {
    16         case 'admin_email':
    17             $value = stripslashes($value);
    18             $value = sanitize_email($value);
    19             break;
    20 
    21         case 'default_post_edit_rows':
    22         case 'mailserver_port':
    23         case 'comment_max_links':
    24             $value = stripslashes($value);
    25             $value = abs((int) $value);
    26             break;
    27 
    28         case 'posts_per_page':
    29         case 'posts_per_rss':
    30             $value = stripslashes($value);
    31             $value = (int) $value;
    32             if ( empty($value) ) $value = 1;
    33             if ( $value < -1 ) $value = abs($value);
    34             break;
    35 
    36         case 'default_ping_status':
    37         case 'default_comment_status':
    38             $value = stripslashes($value);
    39             // Options that if not there have 0 value but need to be something like "closed"
    40             if ( $value == '0' || $value == '')
    41                 $value = 'closed';
    42             break;
    43 
    44         case 'blogdescription':
    45         case 'blogname':
    46             if (current_user_can('unfiltered_html') == false)
    47                 $value = wp_filter_post_kses( $value ); // calls stripslashes then addslashes
    48             $value = stripslashes($value);
    49             break;
    50 
    51         case 'blog_charset':
    52             $value = preg_replace('/[^a-zA-Z0-9_-]/', '', $value); // strips slashes
    53             break;
    54 
    55         case 'date_format':
    56         case 'time_format':
    57         case 'mailserver_url':
    58         case 'mailserver_login':
    59         case 'mailserver_pass':
    60         case 'ping_sites':
    61         case 'upload_path':
    62             $value = strip_tags($value);
    63             $value = wp_filter_kses($value); // calls stripslashes then addslashes
    64             $value = stripslashes($value);
    65             break;
    66 
    67         case 'gmt_offset':
    68             $value = preg_replace('/[^0-9:.-]/', '', $value); // strips slashes
    69             break;
    70 
    71         case 'siteurl':
    72         case 'home':
    73             $value = stripslashes($value);
    74             $value = clean_url($value);
    75             break;
    76         default :
    77             $value = stripslashes($value);
    78             break;
    79     }
    80 
    81     return $value;
    82 }
    8312
    8413switch($action) {
  • tags/2.2.3/wp-admin/rtl.css

    r6063 r6063  
    1 #viewarc, #viewcat, #namediv, #emaildiv, #uridiv, #planetnews li, #login ul li, #your-profile fieldset,
    2     #footer .logo, .alignleft .available-theme { float: right; }
    3 
    4 #templateside, .alignright { float: left; }
    5 
    6 #login #send, .readmore, .widefat th { text-align: right; }
    7 
    8 #postcustomsubmit, form#upload th, .submit, .editform th { text-align: left; }
    9 
    10 #devnews h4, #wphead h1, #your-profile legend, fieldset.options legend,
    11     #planetnews li .post { font-family: Tahoma, Georgia, "Times New Roman", Times, serif; }
    12 
    13 #wphead { padding: .8em 2em .8em 19em; }
    14 
    15 #wphead h1 { font-size: 2.4em; }
    16 
    17 #postdiv, #titlediv, #guiddiv, #tagdiv { margin: 0 0 0 8px; }
    18 
    19 #ed_toolbar input { margin: 3px 0 2px 2px; }
    20 
    21 #edButtons input, #edButtons input:active { margin: 0px 0 -1px 2px; }
    22 
    23 body, td { font: 13px Tahoma, "Lucida Grande", "Lucida Sans Unicode", Verdana; }
    24 
    25 h2 { font: normal 32px/5px serif; }
    26 
    27 textarea, input, select { font:  13px Tahoma, Verdana, Arial, Helvetica, sans-serif; }
    28 
    29 .quicktags, .search { font: 12px Tahoma, Georgia, "Times New Roman", Times, serif; }
    30 
    31 .updated, .confirm { padding: 0 3em 0 1em; }
     1#viewarc, #viewcat, #namediv, #emaildiv, #uridiv, #planetnews li, #login ul li, #your-profile fieldset, #footer .logo, .alignleft .available-theme {
     2    float: right;
     3    }
     4
     5#templateside, .alignright {
     6    float: left;
     7    }
     8
     9#login #send, .readmore, .widefat th {
     10    text-align: right;
     11    }
     12
     13#postcustomsubmit, form#upload th, .submit, .editform th {
     14    text-align: left;
     15    }
     16
     17#devnews h4, #wphead h1, #your-profile legend, fieldset.options legend, #planetnews li .post {
     18    font-family: Tahoma, Georgia, "Times New Roman", Times, serif;
     19    }
     20
     21#wphead {
     22    padding: .8em 2em .8em 19em;
     23    }
     24
     25#wphead h1 {
     26    font-size: 2.4em;
     27    }
     28
     29#postdiv, #titlediv, #guiddiv, #tagdiv {
     30    margin: 0 0 0 8px;
     31    }
     32
     33#ed_toolbar input {
     34    margin: 3px 0 2px 2px;
     35    }
     36
     37#edButtons input, #edButtons input:active {
     38    margin: 0px 0 -1px 2px;
     39    }
     40
     41body, td {
     42    font: 13px Tahoma, "Lucida Grande", "Lucida Sans Unicode", Verdana;
     43    }
     44
     45h1, h2, h3, h4, h5 {
     46    font-family: "Times New Roman", Times, serif;
     47    }
     48h3.dbx-handle {
     49    font-family: tahoma, Verdana, Arial, Helvetica, sans-serif;
     50    }
     51
     52textarea, input, select {
     53    font:  13px Tahoma, Verdana, Arial, Helvetica, sans-serif;
     54    }
     55
     56.quicktags, .search {
     57    font: 12px Tahoma, Georgia, "Times New Roman", Times, serif;
     58    }
     59
     60.updated, .confirm {
     61    padding: 0 3em 0 1em;
     62    }
    3263
    3364.submit input, .submit input:focus, .button, .button:focus {
    3465    border-left-color: #999;
    3566    border-right-color: #ccc;
    36 }
     67    }
    3768
    3869.submit input:active, .button:active {
    3970    border-left-color: #ccc;
    4071    border-right-color: #999;
    41 }
     72    }
    4273
    4374#adminmenu {
    4475    padding: .2em 2em .3em .2em;
    4576    height: 28px;
    46 }
    47 
    48 #adminmenu li { line-height: 160%; }
     77    }
    4978
    5079#adminmenu a {
     
    5281    display: block;
    5382    float: right;
    54 }
     83    font: 700 16px/130% "Times New Roman", Times, serif;
     84    }
    5585
    5686#adminmenu a.current {
    5787    border-right: 0;
    5888    border-left: 2px solid #4f96c8;
    59 }
    60 
    61 #submenu, #minisub { padding: 1px 3em 0 2em; }
    62 
    63 #submenu { height: 28px; }
    64 
    65 #submenu li { line-height: 160%; }
     89    }
     90
     91#submenu, #minisub {
     92    padding: 1px 3em 0 2em;
     93    }
     94
     95#submenu {
     96    height: 28px;
     97    }
    6698
    6799#submenu a {
     
    69101    display: block;
    70102    float: right;
    71 }
     103    line-height: 155%;
     104    }
    72105
    73106#submenu .current {
    74107    border-right: 0;
    75108    border-left: 2px solid #045290;
    76 }
     109    }
    77110
    78111#currenttheme img {
     
    80113    margin-right: auto;
    81114    margin-left: 1em;
    82 }
     115    }
    83116
    84117#postdiv #quicktags {
    85118    padding-right: 0;
    86119    padding-left: 6px;
    87 }
     120    }
    88121
    89122.readmore {
    90123    margin-right: auto;
    91124    margin-left: 5em;
    92 }
     125    }
    93126
    94127#postexcerpt div, #attachmentlinks div {
    95128    margin-right: auto;
    96129    margin-left: 8px;
    97 }
     130    }
    98131
    99132* html #postexcerpt .dbx-toggle-open {
    100133    padding-right: 0;
    101134    padding-left: 8px;
    102 }
     135    }
    103136
    104137#searchform {
     
    106139    margin-right: auto;
    107140    margin-left: 1em;
    108 }
     141    }
    109142
    110143#poststuff {
    111144    margin-right: auto;
    112145    margin-left: 16em;
    113 }
     146    }
    114147
    115148#template div {
    116149    margin-right: auto;
    117150    margin-left: 190px;
    118 }
     151    }
    119152
    120153* html #template div {
    121154    margin-right: auto;
    122155    margin-left: 0px;
    123 }
     156    }
    124157
    125158#user_info {
    126159    right: auto;
    127160    left: 1em;
    128 }
    129 
     161    }
     162   
    130163#zeitgeist {
    131164    float: left;
    132165    margin-left: auto;
    133166    margin-right: 1em;
    134 }
     167    }
    135168
    136169#zeitgeist ul {
    137170    margin: 0 .6em .3em 0;
    138171    padding: 0 .6em 0 0;
    139 }
     172    }
     173
     174.wrap ul {
     175    margin-left: 500px;
     176    }
    140177
    141178#categorydiv ul {
    142179    margin-left: auto;
    143180    margin-right: 10px;
    144 }
    145 
    146 #moremeta fieldset div { margin: 2px 0px 0 0; }
     181    }
    147182
    148183#moremeta {
    149     margin-right: auto;
     184    margin-right: 0;
    150185    margin-left: 15px;
    151186    right: auto;
    152     left: 5%;
    153 }
    154 
     187    left: 6%;
     188    }
     189   
    155190#moremeta .dbx-content {
    156191    background: url(images/box-butt.gif) no-repeat bottom left;
    157     padding-right: 0;
    158     padding-left: 2px;
    159 }
    160 
    161 #moremeta .dbx-handle { background: #2685af url(images/box-head.gif) no-repeat left; }
    162 
    163 #moremeta .dbx-box { background: url(images/box-bg.gif) repeat-y left; }
     192    padding-right: 10px;
     193    padding-left: 0;
     194    text-align: right;
     195    }
     196   
     197#moremeta .dbx-handle {
     198    background: #2685af url(images/box-head.gif) no-repeat left;
     199    margin-top: -2px;
     200    }
     201
     202#moremeta .dbx-box {
     203    background: url(images/box-bg.gif) repeat-y left;
     204    padding-bottom: 0;
     205    }
    164206
    165207a.dbx-toggle, a.dbx-toggle:visited {
    166208    right: auto;
    167209    left: 2px;
    168 }
    169 
    170 #advancedstuff a.dbx-toggle, #advancedstuff a.dbx-toggle-open:visited {
    171     right: auto;
    172     left: 5px;
    173 }
    174 
    175 #advancedstuff a.dbx-toggle-open, #advancedstuff a.dbx-toggle-open:visited {
    176     right: auto;
    177     left: 5px;
    178 }
     210    }
     211
    179212
    180213#categorychecklist {
    181214    margin-right: auto;
    182215    margin-left: 6px;
    183 }
     216    }
    184217
    185218#ajax-response.alignleft {
    186219    margin-left: auto;
    187220    margin-right: 2em;
    188 }
     221    }
    189222
    190223#postdivrich #edButtons {
    191224    padding-left: 0;
    192225    padding-right: 3px;
    193 }
     226    }
    194227
    195228.page-numbers {
    196229    margin-right: auto;
    197230    margin-left: 3px;
    198 }
     231    }
    199232
    200233a.view-link {
     
    203236    margin-right:0;
    204237    margin-left:220px;
    205 }
     238    }
     239#advancedstuff {
     240    direction: ltr;
     241    }
     242#advancedstuff .dbx-handle {
     243    text-align: right;
     244    }
     245#advancedstuff .dbx-content * {
     246    direction: rtl;
     247    }
  • tags/2.2.3/wp-admin/widgets-rtl.css

    r6063 r6063  
    55* html #palettediv ul { padding: 0 10px 0 0; }
    66
    7 #palettediv ul { padding: 0 10px 0 0; }
     7#palettediv ul { padding: 0 10px 0 0;
     8 margin-left: 1px!important;}
    89
    910* .handle, #lastmodule span {
  • tags/2.2.3/wp-includes/default-filters.php

    r6063 r6063  
    130130add_filter('sanitize_title', 'sanitize_title_with_dashes');
    131131
     132add_filter('wp_title', 'wp_specialchars');
     133
    132134// RSS filters
    133135add_filter('the_title_rss', 'strip_tags');
  • tags/2.2.3/wp-includes/feed-rss2-comments.php

    r6063 r6063  
    66<!-- generator="wordpress/<?php echo $wp_version ?>" -->
    77<rss version="2.0"
    8     xmlns:content="http://purl.org/rss/1.0/modules/content/">
     8    xmlns:content="http://purl.org/rss/1.0/modules/content/"
     9    xmlns:dc="http://purl.org/dc/elements/1.1/"
     10    >
    911<channel>
    1012    <title><?php
     
    3840        ?></title>
    3941        <link><?php comment_link() ?></link>
    40         <author><?php echo get_comment_author_rss() ?></author>
     42        <dc:creator><?php echo get_comment_author_rss() ?></dc:creator>
    4143        <pubDate><?php echo mysql2date('D, d M Y H:i:s +0000', get_comment_time('Y-m-d H:i:s', true), false); ?></pubDate>
    4244        <guid><?php comment_link() ?></guid>
  • tags/2.2.3/wp-includes/formatting.php

    r6063 r6063  
    1212    if ( isset($wp_cockneyreplace) ) {
    1313        $cockney = array_keys($wp_cockneyreplace);
    14         $cockney_replace = array_values($wp_cockneyreplace);
     14        $cockneyreplace = array_values($wp_cockneyreplace);
    1515    } else {
    1616        $cockney = array("'tain't","'twere","'twas","'tis","'twill","'til","'bout","'nuff","'round","'cause");
     
    11191119}
    11201120
     1121function sanitize_option($option, $value) { // Remember to call stripslashes!
     1122
     1123    switch ($option) {
     1124        case 'admin_email':
     1125            $value = sanitize_email($value);
     1126            break;
     1127
     1128        case 'default_post_edit_rows':
     1129        case 'mailserver_port':
     1130        case 'comment_max_links':
     1131        case 'page_on_front':
     1132        case 'rss_excerpt_length':
     1133        case 'default_category':
     1134        case 'default_email_category':
     1135        case 'default_link_category':
     1136            $value = abs((int) $value);
     1137            break;
     1138
     1139        case 'posts_per_page':
     1140        case 'posts_per_rss':
     1141            $value = (int) $value;
     1142            if ( empty($value) ) $value = 1;
     1143            if ( $value < -1 ) $value = abs($value);
     1144            break;
     1145
     1146        case 'default_ping_status':
     1147        case 'default_comment_status':
     1148            // Options that if not there have 0 value but need to be something like "closed"
     1149            if ( $value == '0' || $value == '')
     1150                $value = 'closed';
     1151            break;
     1152
     1153        case 'blogdescription':
     1154        case 'blogname':
     1155            $value = addslashes($value);
     1156            $value = wp_filter_post_kses( $value ); // calls stripslashes then addslashes
     1157            $value = stripslashes($value);
     1158            $value = wp_specialchars( $value );
     1159            break;
     1160
     1161        case 'blog_charset':
     1162            $value = preg_replace('/[^a-zA-Z0-9_-]/', '', $value); // strips slashes
     1163            break;
     1164
     1165        case 'date_format':
     1166        case 'time_format':
     1167        case 'mailserver_url':
     1168        case 'mailserver_login':
     1169        case 'mailserver_pass':
     1170        case 'ping_sites':
     1171        case 'upload_path':
     1172            $value = strip_tags($value);
     1173            $value = addslashes($value);
     1174            $value = wp_filter_kses($value); // calls stripslashes then addslashes
     1175            $value = stripslashes($value);
     1176            break;
     1177
     1178        case 'gmt_offset':
     1179            $value = preg_replace('/[^0-9:.-]/', '', $value); // strips slashes
     1180            break;
     1181
     1182        case 'siteurl':
     1183        case 'home':
     1184            $value = stripslashes($value);
     1185            $value = clean_url($value);
     1186            break;
     1187        default :
     1188            break;
     1189    }
     1190
     1191    return $value;
     1192}
     1193
    11211194function wp_parse_str( $string, &$array ) {
    11221195    parse_str( $string, $array );
  • tags/2.2.3/wp-includes/pluggable.php

    r6063 r6063  
    321321    $location = wp_kses_no_null($location);
    322322
     323    // remove %0d and %0a from location
    323324    $strip = array('%0d', '%0a');
    324     $location = str_replace($strip, '', $location);
     325    $found = true;
     326    while($found) {
     327        $found = false;
     328        foreach($strip as $val) {
     329            while(strpos($location, $val) !== false) {
     330                $found = true;
     331                $location = str_replace($val, '', $location);
     332            }
     333        }
     334    }
    325335
    326336    if ( $is_IIS ) {
  • tags/2.2.3/wp-includes/plugin.php

    r6063 r6063  
    2020
    2121    // So the format is wp_filter['tag']['array of priorities']['array of functions serialized']['array of ['array (functions, accepted_args)]']
    22     $wp_filter[$tag][$priority][serialize($function_to_add)] = array('function' => $function_to_add, 'accepted_args' => $accepted_args);
     22    $wp_filter[$tag][$priority][_wp_filter_build_unique_id($tag, $function_to_add, $priority)] = array('function' => $function_to_add, 'accepted_args' => $accepted_args);
    2323    unset( $merged_filters[ $tag ] );
    2424    return true;
     
    9999function remove_filter($tag, $function_to_remove, $priority = 10, $accepted_args = 1) {
    100100    global $wp_filter, $merged_filters;
    101 
    102     unset($GLOBALS['wp_filter'][$tag][$priority][serialize($function_to_remove)]);
     101   
     102    unset($GLOBALS['wp_filter'][$tag][$priority][_wp_filter_build_unique_id($tag, $function_to_remove, $priority)]);
    103103    unset( $merged_filters[ $tag ] );
    104104
     
    236236 */
    237237function plugin_basename($file) {
    238     $file = preg_replace('|\\\\+|', '\\\\', $file);
    239     $file = preg_replace('/^.*wp-content[\\\\\/]plugins[\\\\\/]/', '', $file);
     238    $file = str_replace('\\','/',$file); // sanitize for Win32 installs
     239    $file = preg_replace('|/+|','/', $file); // remove any duplicate slash
     240    $file = preg_replace('|^.*/wp-content/plugins/|','',$file); // get relative path from plugins dir
    240241    return $file;
    241242}
     
    279280}
    280281
     282function _wp_filter_build_unique_id($tag, $function, $priority = 10)
     283{
     284    global $wp_filter;
     285   
     286    // If function then just skip all of the tests and not overwrite the following.
     287    if( is_string($function) )
     288        return $function;
     289    // Object Class Calling
     290    else if(is_object($function[0]) )
     291    {
     292        $obj_idx = get_class($function[0]).$function[1];
     293        if( is_null($function[0]->wp_filter_id) ) {
     294            $count = count((array)$wp_filter[$tag][$priority]);
     295            $function[0]->wp_filter_id = $count;
     296            $obj_idx .= $count;
     297            unset($count);
     298        } else
     299            $obj_idx .= $function[0]->wp_filter_id;
     300        return $obj_idx;
     301    }
     302    // Static Calling
     303    else if( is_string($function[0]) )
     304        return $function[0].$function[1];
     305}
     306
    281307?>
  • tags/2.2.3/wp-includes/query.php

    r6063 r6063  
    414414        $qv = &$this->query_vars;
    415415
    416         if ( ! empty($qv['robots']) ) {
     416        if ( ! empty($qv['robots']) )
    417417            $this->is_robots = true;
    418             return;
    419         }
    420 
    421         if ('404' == $qv['error']) {
    422             $this->is_404 = true;
    423             if ( !empty($query) ) {
    424                 do_action_ref_array('parse_query', array(&$this));
    425             }
    426             return;
    427         }
    428418
    429419        $qv['p'] =  (int) $qv['p'];
     
    607597        }
    608598
     599        if ( !empty($qv['post_type']) )
     600            $qv['post_type'] = sanitize_user($qv['post_type'], true);
     601
     602        if ( !empty($qv['post_status']) )
     603            $qv['post_status'] = sanitize_user($qv['post_status'], true);
     604
    609605        if ( $this->is_posts_page && !$qv['withcomments'] )
    610606            $this->is_comment_feed = false;
     
    612608        $this->is_singular = $this->is_single || $this->is_page || $this->is_attachment;
    613609        // Done correcting is_* for page_on_front and page_for_posts
     610
     611        if ('404' == $qv['error'])
     612            $this->set_404();
    614613
    615614        if ( !empty($query) )
  • tags/2.2.3/wp-includes/rewrite.php

    r6063 r6063  
    136136            // Substitute the substring matches into the query.
    137137            eval("\$query = \"$query\";");
     138            // Filter out non-public query vars
     139            global $wp;
     140            parse_str($query, $query_vars);
     141            $query = array();
     142            foreach ( $query_vars as $key => $value ) {
     143                if ( in_array($key, $wp->public_query_vars) )
     144                    $query[$key] = $value;
     145            }
     146            // Do the query
    138147            $query = new WP_Query($query);
    139148            if ( $query->is_single || $query->is_page )
  • tags/2.2.3/wp-includes/rss.php

    r6063 r6063  
    1010define('RSS', 'RSS');
    1111define('ATOM', 'Atom');
    12 define('MAGPIE_USER_AGENT', 'WordPress/' . $wp_version);
     12define('MAGPIE_USER_AGENT', 'WordPress/' . $GLOBALS['wp_version']);
    1313
    1414class MagpieRSS {
     
    592592
    593593    if ( !defined('MAGPIE_USER_AGENT') ) {
    594         $ua = 'WordPress/' . $wp_version;
     594        $ua = 'WordPress/' . $GLOBALS['wp_version'];
    595595
    596596        if ( MAGPIE_CACHE_ON ) {
  • tags/2.2.3/wp-includes/vars.php

    r6063 r6063  
    22
    33// On which page are we ?
    4 if ( preg_match('#([^/]+\.php)$#', $PHP_SELF, $self_matches) ) {
     4if ( is_admin() ) {
     5    // wp-admin pages are checked more carefully
     6    preg_match('#/wp-admin/?(.*?)$#i', $PHP_SELF, $self_matches);
    57    $pagenow = $self_matches[1];
    6 } elseif ( strpos($PHP_SELF, '?') !== false ) {
    7     $pagenow = explode('/', $PHP_SELF);
    8     $pagenow = trim($pagenow[(sizeof($pagenow)-1)]);
    9     $pagenow = explode('?', $pagenow);
    10     $pagenow = $pagenow[0];
     8    $pagenow = preg_replace('#\?.*?$#', '', $pagenow);
     9    if ( '' === $pagenow || 'index' === $pagenow || 'index.php' === $pagenow ) {
     10        $pagenow = 'index.php';
     11    } else {
     12        preg_match('#(.*?)(/|$)#', $pagenow, $self_matches);
     13        $pagenow = strtolower($self_matches[1]);
     14        if ( '.php' !== substr($pagenow, -4, 4) )
     15            $pagenow .= '.php'; // for Options +Multiviews: /wp-admin/themes/index.php (themes.php is queried)
     16    }
    1117} else {
    12     $pagenow = 'index.php';
     18    if ( preg_match('#([^/]+\.php)([?/].*?)?$#i', $PHP_SELF, $self_matches) )
     19        $pagenow = strtolower($self_matches[1]);
     20    else
     21        $pagenow = 'index.php';
    1322}
    1423
  • tags/2.2.3/wp-includes/version.php

    r6063 r6063  
    33// This holds the version number in a separate file so we can bump it without cluttering the SVN
    44
    5 $wp_version = '2.2.2';
     5$wp_version = '2.2.3';
    66$wp_db_version = 5183;
    77
  • tags/2.2.3/wp-includes/widgets.php

    r6063 r6063  
    333333    $title = empty( $options['title'] ) ? __( 'Pages' ) : $options['title'];
    334334    $sortby = empty( $options['sortby'] ) ? 'menu_order' : $options['sortby'];
    335     $exclude = empty( $options['exclude'] ) ? '' : '&exclude=' . $options['exclude'];
     335    $exclude = empty( $options['exclude'] ) ? '' : $options['exclude'];
    336336   
    337337    if ( $sortby == 'menu_order' ) {
     
    339339    }
    340340   
    341     $out = wp_list_pages( 'title_li=&echo=0&sort_column=' . $sortby . $exclude );
     341    $out = wp_list_pages( array('title_li' => '', 'echo' => 0, 'sort_column' => $sortby, 'exclude' => $exclude) );
    342342   
    343343    if ( !empty( $out ) ) {
  • tags/2.2.3/wp-mail.php

    r6063 r6063  
    6565            if (preg_match('/From: /', $line) | preg_match('/Reply-To: /', $line))  {
    6666                $author=trim($line);
    67             if ( ereg("([a-zA-Z0-9\_\-\.]+@[\a-zA-z0-9\_\-\.]+)", $author , $regs) ) {
    68                 $author = $regs[1];
    69                 echo "Author = {$author} <p>";
    70                 $author = $wpdb->escape($author);
    71                 $result = $wpdb->get_row("SELECT ID FROM $wpdb->users WHERE user_email='$author' LIMIT 1");
    72                 if (!$result)
     67                if ( ereg("([a-zA-Z0-9\_\-\.]+@[\a-zA-z0-9\_\-\.]+)", $author , $regs) ) {
     68                    $author = $regs[1];
     69                    echo "Author = {$author} <p>";
     70                    $author = $wpdb->escape($author);
     71                    $result = $wpdb->get_row("SELECT ID FROM $wpdb->users WHERE user_email='$author' LIMIT 1");
     72                    if (!$result)
     73                        $post_author = 1;
     74                    else
     75                        $post_author = $result->ID;
     76                } else
    7377                    $post_author = 1;
    74                 else
    75                     $post_author = $result->ID;
    76             } else
    77                 $post_author = 1;
    7878            }
    7979
  • tags/2.2.3/xmlrpc.php

    r6063 r6063  
    10341034        if(isset($content_struct["mt_allow_pings"])) {
    10351035            if(!is_numeric($content_struct["mt_allow_pings"])) {
    1036                 switch($content["mt_allow_pings"]) {
     1036                switch($content_struct["mt_allow_pings"]) {
    10371037                    case "closed":
    10381038                        $ping_status = "closed";
     
    12461246        if(isset($content_struct["mt_allow_pings"])) {
    12471247            if(!is_numeric($content_struct["mt_allow_pings"])) {
    1248                 switch($content["mt_allow_pings"]) {
     1248                switch($content_struct["mt_allow_pings"]) {
    12491249                    case "closed":
    12501250                        $ping_status = "closed";
Note: See TracChangeset for help on using the changeset viewer.