Changeset 1239
- Timestamp:
- 05/07/2004 11:56:33 PM (22 years ago)
- Location:
- trunk
- Files:
-
- 16 edited
-
wp-admin/categories.php (modified) (3 diffs)
-
wp-admin/edit-comments.php (modified) (1 diff)
-
wp-admin/edit-form.php (modified) (3 diffs)
-
wp-admin/edit.php (modified) (1 diff)
-
wp-admin/moderation.php (modified) (1 diff)
-
wp-admin/options-head.php (modified) (3 diffs)
-
wp-admin/plugins.php (modified) (6 diffs)
-
wp-admin/post.php (modified) (1 diff)
-
wp-admin/profile.php (modified) (1 diff)
-
wp-admin/templates.php (modified) (1 diff)
-
wp-admin/users.php (modified) (2 diffs)
-
wp-includes/functions-formatting.php (modified) (1 diff)
-
wp-includes/functions.php (modified) (3 diffs)
-
wp-includes/template-functions-general.php (modified) (1 diff)
-
wp-login.php (modified) (1 diff)
-
wp-settings.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/categories.php
r1204 r1239 3 3 4 4 $title = __('Categories'); 5 /* <Categories> */6 5 7 6 function add_magic_quotes($array) { … … 145 144 $messages[3] = __('Category updated.'); 146 145 ?> 147 <?php if ( $_GET['message']) : ?>146 <?php if (isset($_GET['message'])) : ?> 148 147 <div class="updated"><p><?php echo $messages[$_GET['message']]; ?></p></div> 149 148 <?php endif; ?> … … 194 193 } 195 194 196 /* </Categories> */197 195 include('admin-footer.php'); 198 196 ?> -
trunk/wp-admin/edit-comments.php
r1131 r1239 32 32 <fieldset> 33 33 <legend><?php _e('Show Comments That Contain...') ?></legend> 34 <input type="text" name="s" value="<?php echo $s; ?>" size="17" />34 <input type="text" name="s" value="<?php if (isset($s)) echo $s; ?>" size="17" /> 35 35 <input type="submit" name="submit" value="<?php _e('Search') ?>" /> 36 36 <input type="hidden" name="mode" value="<?php echo $mode; ?>" /> -
trunk/wp-admin/edit-form.php
r1233 r1239 19 19 $form_trackback = '<p><label for="trackback">' . sprintf(__('<a href="%s" title="Help on trackbacks"><strong>TrackBack</strong> an <acronym title="Uniform Resource Locator">URL</acronym></a>:</label> (Separate multiple <abbr title="Universal Resource Identifier">URI</abbr>s with spaces.)<br />'), 'http://wordpress.org/docs/reference/post/#trackback') . 20 20 '<input type="text" name="trackback_url" style="width: 360px" id="trackback" tabindex="7" /></p>'; 21 if ('' != $pinged) {22 $form_trackback .= '<p>' . __('Already pinged:') . '</p><ul>';23 $already_pinged = explode("\n", trim($pinged));24 foreach ($already_pinged as $pinged_url) {25 $form_trackback .= "\n\t<li>$pinged_url</li>";26 }27 $form_trackback .= '</ul>';28 }29 21 } else { 30 22 $form_trackback = ''; … … 39 31 40 32 <?php 41 if ( 'bookmarklet' == $mode) {33 if (isset($mode) && 'bookmarklet' == $mode) { 42 34 echo '<input type="hidden" name="mode" value="bookmarklet" />'; 43 35 } … … 99 91 100 92 <?php echo $form_pingback ?> 101 <?php echo $form_prevstatus ?>102 93 <?php echo $form_trackback; ?> 103 94 <p><input name="saveasdraft" type="submit" id="saveasdraft" tabindex="9" value="<?php _e('Save as Draft') ?>" /> -
trunk/wp-admin/edit.php
r1213 r1239 71 71 <fieldset> 72 72 <legend><?php _e('Show Posts That Contain...') ?></legend> 73 <input type="text" name="s" value="<?php echo $s; ?>" size="17" />73 <input type="text" name="s" value="<?php if (isset($s)) echo $s; ?>" size="17" /> 74 74 <input type="submit" name="submit" value="<?php _e('Search') ?>" /> 75 75 </fieldset> -
trunk/wp-admin/moderation.php
r1163 r1239 104 104 </ul> 105 105 <?php 106 $ignored = $_GET['ignored'];107 $deleted = $_GET['deleted'];108 $approved = $_GET['approved'];109 106 110 if ( ($deleted) || ($approved) ||($ignored)) {107 if (isset($deleted) || isset($approved) || isset($ignored)) { 111 108 echo "<div class='updated'>\n<p>"; 112 109 if ($approved) { -
trunk/wp-admin/options-head.php
r1193 r1239 2 2 3 3 if ($user_level <= 6) { 4 die( __("You have do not have sufficient permissions to edit the options for this blog."));4 die( __('You have do not have sufficient permissions to edit the options for this blog.') ); 5 5 } 6 6 7 7 //we need to iterate through the available option groups. 8 $groups = ''; 8 9 $option_groups = $wpdb->get_results("SELECT group_id, group_name, group_desc, group_longdesc FROM $tableoptiongroups ORDER BY group_id"); 9 10 foreach ($option_groups as $option_group) { … … 29 30 $_SERVER['REQUEST_URI'] = str_replace('?updated=true', '', $_SERVER['REQUEST_URI']); 30 31 foreach ($sublines as $subline) { 31 preg_match('/href="([^"]+)"/', $subline, $url); 32 if (substr($_SERVER['REQUEST_URI'], -8) == substr($url[1], -8)) { 33 $subline = str_replace('a hr', 'a class="current" hr', $subline); 34 if (str_replace('/wp-admin/', '', $_SERVER["REQUEST_URI"]) == $url[1]) { 35 $subline = preg_replace('|href=".*?"|', '', $subline); 32 if (preg_match('/href="([^"]+)"/', $subline, $url)) { 33 if (substr($_SERVER['REQUEST_URI'], -8) == substr($url[1], -8)) { 34 $subline = str_replace('a hr', 'a class="current" hr', $subline); 35 if (str_replace('/wp-admin/', '', $_SERVER["REQUEST_URI"]) == $url[1]) { 36 $subline = preg_replace('|href=".*?"|', '', $subline); 37 } 36 38 } 37 39 } … … 45 47 <br clear="all" /> 46 48 47 <?php if ( $updated) : ?>49 <?php if (isset($updated)) : ?> 48 50 <div class="updated"><p><strong><?php _e('Options saved.') ?></strong></p></div> 49 51 <?php endif; ?> -
trunk/wp-admin/plugins.php
r1173 r1239 47 47 ?> 48 48 49 <?php if ( $_GET['activate']) : ?>49 <?php if (isset($_GET['activate'])) : ?> 50 50 <div class="updated"><p><?php _e('Plugin <strong>activated</strong>.') ?></p> 51 51 </div> 52 52 <?php endif; ?> 53 <?php if ( $_GET['deactivate']) : ?>53 <?php if (isset($_GET['deactivate'])) : ?> 54 54 <div class="updated"><p><?php _e('Plugin <strong>deactivated</strong>.') ?></p> 55 55 </div> … … 87 87 <?php 88 88 sort($plugin_files); // Alphabetize by filename. Better way? 89 $style = ''; 89 90 foreach($plugin_files as $plugin_file) { 90 91 $plugin_data = implode('', file(ABSPATH . '/wp-content/plugins/' . $plugin_file)); … … 94 95 preg_match("|Author:(.*)|i", $plugin_data, $author_name); 95 96 preg_match("|Author URI:(.*)|i", $plugin_data, $author_uri); 96 preg_match("|Version:(.*)|i", $plugin_data, $version); 97 $description = wptexturize(wp_filter_kses($description[1])); 97 if ( preg_match("|Version:(.*)|i", $plugin_data, $version) ) 98 $version = $version[1]; 99 else 100 $version =''; 101 102 $description = wptexturize($description[1]); 98 103 99 104 if ('' == $plugin_uri) { 100 105 $plugin = $plugin_name[1]; 101 106 } else { 102 $plugin = wp_filter_kses( __("<a href='{$plugin_uri[1]}' title='Visit plugin homepage'>{$plugin_name[1]}</a>"));107 $plugin = __("<a href='{$plugin_uri[1]}' title='Visit plugin homepage'>{$plugin_name[1]}</a>"); 103 108 } 104 109 … … 106 111 $author = $author_name[1]; 107 112 } else { 108 $author = wp_filter_kses( __("<a href='{$author_uri[1]}' title='Visit author homepage'>{$author_name[1]}</a>"));113 $author = __("<a href='{$author_uri[1]}' title='Visit author homepage'>{$author_name[1]}</a>"); 109 114 } 110 115 … … 122 127 <tr $style> 123 128 <td>$plugin</td> 124 <td> {$version[1]}</td>129 <td>$version</td> 125 130 <td>$author</td> 126 131 <td>$description</td> … … 137 142 138 143 <?php 139 140 144 include('admin-footer.php'); 141 145 ?> -
trunk/wp-admin/post.php
r1236 r1239 696 696 697 697 if ($user_level > 0) { 698 if ((!$withcomments) && (!$single)) { 699 700 $action = 'post'; 701 get_currentuserinfo(); 702 $drafts = $wpdb->get_results("SELECT ID, post_title FROM $tableposts WHERE post_status = 'draft' AND post_author = $user_ID"); 703 if ($drafts) { 704 ?> 705 <div class="wrap"> 706 <p><strong><?php _e('Your Drafts:') ?></strong> 707 <?php 708 $i = 0; 709 foreach ($drafts as $draft) { 710 if (0 != $i) 711 echo ', '; 712 $draft->post_title = stripslashes($draft->post_title); 713 if ($draft->post_title == '') 714 $draft->post_title = sprintf(__('Post # %s'), $draft->ID); 715 echo "<a href='post.php?action=edit&post=$draft->ID' title='" . __('Edit this draft') . "'>$draft->post_title</a>"; 716 ++$i; 717 } 718 ?>.</p> 719 </div> 720 <?php 721 } 722 //set defaults 723 $post_status = get_settings('default_post_status'); 724 $comment_status = get_settings('default_comment_status'); 725 $ping_status = get_settings('default_ping_status'); 726 $post_pingback = get_settings('default_pingback_flag'); 727 $default_post_cat = get_settings('default_post_category'); 728 729 if (get_settings('advanced_edit')) { 730 include('edit-form-advanced.php'); 731 } else { 732 include('edit-form.php'); 733 } 698 $action = 'post'; 699 get_currentuserinfo(); 700 $drafts = $wpdb->get_results("SELECT ID, post_title FROM $tableposts WHERE post_status = 'draft' AND post_author = $user_ID"); 701 if ($drafts) { 702 ?> 703 <div class="wrap"> 704 <p><strong><?php _e('Your Drafts:') ?></strong> 705 <?php 706 $i = 0; 707 foreach ($drafts as $draft) { 708 if (0 != $i) 709 echo ', '; 710 $draft->post_title = stripslashes($draft->post_title); 711 if ($draft->post_title == '') 712 $draft->post_title = sprintf(__('Post # %s'), $draft->ID); 713 echo "<a href='post.php?action=edit&post=$draft->ID' title='" . __('Edit this draft') . "'>$draft->post_title</a>"; 714 ++$i; 715 } 716 ?>.</p> 717 </div> 718 <?php 719 } 720 //set defaults 721 $post_status = get_settings('default_post_status'); 722 $comment_status = get_settings('default_comment_status'); 723 $ping_status = get_settings('default_ping_status'); 724 $post_pingback = get_settings('default_pingback_flag'); 725 $default_post_cat = get_settings('default_post_category'); 726 727 if (get_settings('advanced_edit')) { 728 include('edit-form-advanced.php'); 729 } else { 730 include('edit-form.php'); 734 731 } 735 732 ?> -
trunk/wp-admin/profile.php
r1161 r1239 225 225 226 226 ?> 227 <?php if ( $updated) { ?>227 <?php if (isset($updated)) { ?> 228 228 <div class="updated"> 229 229 <p><strong><?php _e('Profile updated.') ?></strong></p> -
trunk/wp-admin/templates.php
r1176 r1239 114 114 115 115 ?> 116 <?php if ( 'te' == $_GET['a']) : ?>116 <?php if (isset($_GET['a'])) : ?> 117 117 <div class="updated"><p><?php _e('File edited successfully.') ?></p></div> 118 118 <?php endif; ?> -
trunk/wp-admin/users.php
r1233 r1239 165 165 include ('admin-header.php'); 166 166 ?> 167 <?php if ( $_GET['deleted']) : ?>167 <?php if (isset($_GET['deleted'])) : ?> 168 168 <div class="updated"><p><?php _e('User deleted.') ?></p></div> 169 169 <?php endif; ?> … … 182 182 <?php 183 183 $users = $wpdb->get_results("SELECT ID FROM $tableusers WHERE user_level > 0 ORDER BY ID"); 184 $style = ''; 184 185 foreach ($users as $user) { 185 186 $user_data = get_userdata($user->ID); -
trunk/wp-includes/functions-formatting.php
r1150 r1239 224 224 function format_to_post($content) { 225 225 global $wpdb; 226 $content = stripslashes(stripslashes($content));227 226 $content = apply_filters('format_to_post', $content); 228 $content = $wpdb->escape($content);229 227 return $content; 230 228 } -
trunk/wp-includes/functions.php
r1235 r1239 1 1 <?php 2 3 $curpath = dirname(__FILE__).'/';4 5 require($curpath . 'functions-formatting.php');6 2 7 3 if (!function_exists('_')) { … … 846 842 global $posts; 847 843 848 if (empty($post_list)) { 849 $post_list = $posts; 850 } 851 852 if (count($post_list) == 1) { 844 if ($posts && 1 === count($posts)) { 853 845 // there's only one result see if it has a geo code 854 $row = $post _list[0];846 $row = $posts[0]; 855 847 $lat = $row->post_lat; 856 848 $lon = $row->post_lon; … … 865 857 if(get_settings('use_default_geourl')) { 866 858 // send the default here 867 echo "<meta name= \"ICBM\"content=\"". get_settings('default_geourl_lat') .", ". get_settings('default_geourl_lon') ."\" />\n";868 echo "<meta name= \"DC.title\"content=\"".convert_chars(strip_tags(get_bloginfo("name")))."\" />\n";869 echo "<meta name= \"geo.position\"content=\"". get_settings('default_geourl_lat') .";". get_settings('default_geourl_lon') ."\" />\n";859 echo "<meta name='ICBM' content=\"". get_settings('default_geourl_lat') .", ". get_settings('default_geourl_lon') ."\" />\n"; 860 echo "<meta name='DC.title' content=\"".convert_chars(strip_tags(get_bloginfo("name")))."\" />\n"; 861 echo "<meta name='geo.position' content=\"". get_settings('default_geourl_lat') .";". get_settings('default_geourl_lon') ."\" />\n"; 870 862 } 871 863 } -
trunk/wp-includes/template-functions-general.php
r1235 r1239 485 485 function allowed_tags() { 486 486 global $allowedtags; 487 $allowed = ''; 487 488 foreach($allowedtags as $tag => $attributes) { 488 489 $allowed .= '<'.$tag; -
trunk/wp-login.php
r1203 r1239 121 121 $user_login = $log; 122 122 $user_pass = $pwd; 123 setcookie('wordpressuser_'.$cookiehash, $user_login, time()+31536000); 124 setcookie('wordpresspass_'.$cookiehash, md5($user_pass), time()+31536000); 125 if (empty($_COOKIE['wordpressblogid_'.$cookiehash])) { 126 setcookie('wordpressblogid_'.$cookiehash, 1,time()+31536000); 127 } 123 setcookie('wordpressuser_'.$cookiehash, $user_login, time() + 31536000, COOKIEPATH); 124 setcookie('wordpresspass_'.$cookiehash, md5($user_pass), time() + 31536000, COOKIEPATH); 125 128 126 header('Expires: Wed, 11 Jan 1984 05:00:00 GMT'); 129 127 header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); -
trunk/wp-settings.php
r1219 r1239 38 38 39 39 require (ABSPATH . WPINC . '/functions.php'); 40 require (ABSPATH . WPINC . '/functions-formatting.php'); 40 41 require (ABSPATH . 'wp-config-extra.php'); 41 42 require (ABSPATH . WPINC . '/template-functions.php');
Note: See TracChangeset
for help on using the changeset viewer.