Add populate_options action. Props RanYanivHartstein. fixes #6854
git-svn-id: http://svn.automattic.com/wordpress/trunk@7848 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
ded2d7929d
commit
45302a3d9a
|
@ -156,6 +156,9 @@ function populate_options() {
|
||||||
|
|
||||||
$schema = ( isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on' ) ? 'https://' : 'http://';
|
$schema = ( isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on' ) ? 'https://' : 'http://';
|
||||||
$guessurl = preg_replace('|/wp-admin/.*|i', '', $schema . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']);
|
$guessurl = preg_replace('|/wp-admin/.*|i', '', $schema . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']);
|
||||||
|
|
||||||
|
do_action('populate_options');
|
||||||
|
|
||||||
add_option('siteurl', $guessurl);
|
add_option('siteurl', $guessurl);
|
||||||
add_option('blogname', __('My Blog'));
|
add_option('blogname', __('My Blog'));
|
||||||
add_option('blogdescription', __('Just another WordPress weblog'));
|
add_option('blogdescription', __('Just another WordPress weblog'));
|
||||||
|
|
Loading…
Reference in New Issue