Support » Fixing WordPress » how to restore theme settings

  • Resolved HTimes_admin


    Hi there, I need some help restoring my default theme setting. I tried to update my single.php by adding some code that would display related posts at the end of each post, but once I did that, my theme converted to a single post blog style. I’ve tried to update all the settings in the Appearance section, including all the navigation and menus, but it still hasn’t restored the theme.

    Here is my site:

    Please help.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Christine Rondeau


    Volunteer Forum Moderator

    Unfortunately the only way to go back is to upload another copy of the single.php file.
    Do you have a back up of the theme? I would re-upload it and hopefully that will do the trick.

    Hi Christine,

    No, I don’t have a backup of the theme. How do I create one? Also, if I re-upload it, I’ll lose all of my settings.

    Christine Rondeau


    Volunteer Forum Moderator

    The settings are stored in your database, so that should be fine. If the changes that happened resulted in the changes you made to the single.php file, can you not revert these?

    Where is your site hosted? Some hosts can roll back your site to what it was a few days ago.

    If not, then perhaps you can explain a bit better what you are trying to accomplish.

    You mentioned, modifying the single.php file to show related posts and then your theme converted to a single post blog style. That’s a bit strange and I’m not sure what you mean.

    How is your site supposed to behave and display?

    The theme that you are using is this one –
    If you only made a change to the single.php file, can you not go and grab a fresh copy and just replace your current one?

    These tips very helpful. I will try all that you suggest.

    To answer your questions:

    -My site is hosted with Network Solutions and I’ll check if they can roll back the site.

    -I found a code to display related posts (below) and I added it to the single.php, but as soon as I did that, my home page settings changed. So I copied the old single.php code, that didn’t work. Lastly, I restored my default settings in the Theme Options and Appearance sections, and neither worked.

    Found this code on

    02	//for use in the loop, list 5 post titles related to first tag on current post
    03	$tags = wp_get_post_tags($post->ID);
    04	if ($tags) {
    05	echo 'Related Posts';
    06	$first_tag = $tags[0]->term_id;
    07	$args=array(
    08	'tag__in' => array($first_tag),
    09	'post__not_in' => array($post->ID),
    10	'showposts'=>5,
    11	'caller_get_posts'=>1
    12	);
    13	$my_query = new WP_Query($args);
    14	if( $my_query->have_posts() ) {
    15	while ($my_query->have_posts()) : $my_query->the_post(); ?>
    16	<a>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a>
    18	<?php
    19	endwhile;
    20	}
    21	wp_reset_query();
    22	}
    23	?>

    That code was for related posts

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘how to restore theme settings’ is closed to new replies.