• I have issues with the css style sheets. I moved my sidebar from the left to the right by placing my <?php get_sidebar(); ?> before the <div id=”container”> in my index.php file. Both divs are styled to float to the left. The change works in my homepage, but when I navigate to other pages, the sidebar is still on the right side. Other styling changes seem to work in all pages, but this one does not. I am new to this and would appreciate any input. Thanks!!

Viewing 5 replies - 1 through 5 (of 5 total)
  • I’m guessing that you didn’t make the sidebar move in single.php and page.php (your single post and page view files). This will stop the move.

    Thread Starter lzweigle

    (@lzweigle)

    How do I accomplish that? This may sound stupid, but what does single.php and page.php do? I noticed that my source for my pages showed the container div ahead of the sidebar head, whereas in my homepage the sidebar was first. Thanks again! This is my first week. I am using WAMPS as my local server and have made some progress in the design area.

    Thread Starter lzweigle

    (@lzweigle)

    Give me a minute and I will figure this out! Thanks! I went to the page.php and single.php pages and reordered the divs and everything works great. I just don’t understand how wordpress uses those files.

    basically, when wordpress looks to create a page on your blog, it looks at the index.php last, even for single posts, pages, etc. But, if you have a single.php or pages.php, WordPress will always look at those files BEFORE it looks at index.php. I know it’s sort of confusing, but I hope that helps.

    To answer your earlier question:
    Single.php decides what the page for looking at a single post on your blog will look like.

    Pages.php decides what the page for looking at a single page on your blog will look like.

    Thread Starter lzweigle

    (@lzweigle)

    Thanks! I had created these pages but did not know their purpose.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Sidebar on opposite sides!’ is closed to new replies.