WordPress.org

Forums

Can't Change Privacy Setting (9 posts)

  1. admania
    Member
    Posted 7 years ago #

    Hi there

    I created 2 new blogs today just the same as I have always done but I noticed under options then privacy in wordpress, the "i would like to block search engines" had been selected. When I went to change this option I got the following error

    Fatal error: Cannot redeclare sanitize_option() (previously declared in /home/learn/public_html/wp-admin/options.php:13) in /home/learn/public_html/wp-includes/formatting.php on line 1121

    I am now concerned for whatever reason that my blogs are being blocked to google spiders etc. Can you suggest what i can do?

    Thanks

    Adam

  2. fool4Christ
    Member
    Posted 7 years ago #

    Adam, I'm not sure what would be causing the Fatal Error; however, I can suggest an alternative means of switching the privacy options.

    Visit wp-admin/options.php on your blog. If you haven't come across this screen before, don't be surprised -- it's not linked to anywhere within the admin panel. It's purpose is simply to show all of your blog's configuration options -- anything placed in the options table of your database, whether plugin, theme, or core. Be careful what you change within this screen!

    Anyway, you'll want to find the blog_public option in that list. If you want your blog to be indexed by search engines, make sure blog_public option is set to 1 and save.

    Finally, visit your blog and View Source. Ensure that the following bit of code does not appear:

    <meta name='robots' content='noindex,nofollow' />

  3. spencerp
    Member
    Posted 7 years ago #

    Will something in this thread help for the error itself, maybe? Good luck.

  4. admania
    Member
    Posted 7 years ago #

    Ok thanks for your replies but I have the same problem. Firstly i found nothing that you suggested in wp admin options although in wp admin options-privacy.php I found the following

    <p><input id="blog-public" type="radio" name="blog_public" value="1" <?php checked('1', get_option('blog_public')); ?> />
    <label for="blog-public"><?php _e('I would like my blog to be visible to everyone, including search engines (like Google, Sphere, Technorati) and archivers');?></label></p>
    <p><input id="blog-norobots" type="radio" name="blog_public" value="0" <?php checked('0', get_option('blog_public')); ?> />
    <label for="blog-norobots"><?php _e('I would like to block search engines, but allow normal visitors'); ?></label></p>
    <?php do_action('blog_privacy_selector'); ?>
    </td>

    That seems ok though isn't it?
    Spencer I checked out the thread you mentioned which was exactly the same type of error but the guy was very vague describing what he did so I can't really follow. Please someone help as it's driving me round the bend. Thanka

  5. fool4Christ
    Member
    Posted 7 years ago #

    I didn't mean view the PHP code of your admin panel pages. When you login to your admin panel, you can change the URL to point to options.php (in the wp-admin/ folder); on that page, you'll be able to update the option, regardless of whether the options-privacy.php page is working properly or not.

    And you might try reuploading options-privacy.php (or even the entire wp-admin/ folder) for whatever version of WordPress you are using.

  6. admania
    Member
    Posted 7 years ago #

    Hi there

    I know this frustrating but talk me through exactly what i need to do

    "When you login to your admin panel, you can change the URL to point to options.php (in the wp-admin/ folder); on that page, you'll be able to update the option, regardless of whether the options-privacy.php page is working properly or not"

    Where do i exactly need to go to do this?
    thanks
    adam

  7. Something like this (use your own domain name, of course):

    http://www.example.com/wordpress/wp-admin/options.php

    You'll see a quite long list...

  8. admania
    Member
    Posted 7 years ago #

    Thanks but i'm getting the same old error

    Fatal error: Cannot redeclare sanitize_option() (previously declared in /home/toyota/public_html/wp-admin/options.php:13) in /home/toyota/public_html/wp-includes/formatting.php on line 1121

  9. Make certain that you have the correct versions of all the WordPress files. When you upgraded, you may not have upgraded some of your files.

    Download a fresh copy of WordPress if you need clean versions of those files.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.