Ticket #4003: trunk-4003.diff
File trunk-4003.diff, 4.0 KB (added by , 18 years ago) |
---|
-
wp-includes/default-filters.php
145 145 // Misc filters 146 146 add_filter('option_ping_sites', 'privacy_ping_filter'); 147 147 add_filter('option_blog_charset', 'wp_specialchars'); 148 add_filter('option_home', '_config_wp_home'); 149 add_filter('option_siteurl', '_config_wp_siteurl'); 148 150 add_filter('mce_plugins', '_mce_load_rtl_plugin'); 149 151 add_filter('mce_buttons', '_mce_add_direction_buttons'); 150 152 … … 171 173 add_action('admin_print_scripts', 'wp_print_scripts', 20); 172 174 add_action('mce_options', '_mce_set_direction'); 173 175 add_action('init', 'smilies_init', 5); 174 ?> 175 No newline at end of file 176 ?> -
wp-includes/functions.php
993 993 $wpdb->hide_errors(); 994 994 $installed = $wpdb->get_var("SELECT option_value FROM $wpdb->options WHERE option_name = 'siteurl'"); 995 995 $wpdb->show_errors(); 996 return $installed; 996 997 $install_status = !empty( $installed ) ? TRUE : FALSE; 998 return $install_status; 997 999 } 998 1000 999 1001 function wp_nonce_url($actionurl, $action = -1) { … … 1351 1353 die(); 1352 1354 } 1353 1355 1356 function _config_wp_home($url = '') { 1357 if ( defined( 'WP_HOME' ) ) 1358 return WP_HOME; 1359 else return $url; 1360 } 1361 1362 function _config_wp_siteurl($url = '') { 1363 if ( defined( 'WP_SITEURL' ) ) 1364 return WP_SITEURL; 1365 else return $url; 1366 } 1367 1354 1368 function _mce_set_direction() { 1355 1369 global $wp_locale; 1356 1370 … … 1443 1457 } 1444 1458 } 1445 1459 1446 ?> 1447 No newline at end of file 1460 ?> -
wp-admin/upgrade-functions.php
21 21 update_option('admin_email', $user_email); 22 22 update_option('blog_public', $public); 23 23 $schema = ( isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on' ) ? 'https://' : 'http://'; 24 $guessurl = preg_replace('|/wp-admin/.*|i', '', $schema . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']); 24 25 if( defined('WP_SITEURL') && '' != WP_SITEURL ) { 26 $guessurl = WP_SITEURL; 27 } else { 28 $guessurl = preg_replace('|/wp-admin/.*|i', '', $schema . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']); 29 } 25 30 update_option('siteurl', $guessurl); 26 31 27 32 // If not a public blog, don't ping. -
wp-admin/options-general.php
25 25 </tr> 26 26 <tr valign="top"> 27 27 <th scope="row"><?php _e('WordPress address (URL):') ?></th> 28 <td><input name="siteurl" type="text" id="siteurl" value="<?php form_option('siteurl'); ?>" size="40" class="code "/></td>28 <td><input name="siteurl" type="text" id="siteurl" value="<?php form_option('siteurl'); ?>" size="40" class="code<?php if ( defined( 'WP_SITEURL' ) ) : ?> disabled" disabled="disabled"<?php else: ?>"<?php endif; ?> /></td> 29 29 </tr> 30 30 <tr valign="top"> 31 31 <th scope="row"><?php _e('Blog address (URL):') ?></th> 32 <td><input name="home" type="text" id="home" value="<?php form_option('home'); ?>" size="40" class="code "/><br /><?php _e('If you want your blog homepage <a href="http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory">to be different than the directory</a> you installed WordPress in, enter that address here.'); ?></td>32 <td><input name="home" type="text" id="home" value="<?php form_option('home'); ?>" size="40" class="code<?php if ( defined( 'WP_HOME' ) ) : ?> disabled" disabled="disabled"<?php else: ?>"<?php endif; ?> /><br /><?php _e('If you want your blog homepage <a href="http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory">to be different than the directory</a> you installed WordPress in, enter that address here.'); ?></td> 33 33 </tr> 34 34 <tr valign="top"> 35 35 <th scope="row"><?php _e('E-mail address:') ?> </th>