WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Move Right Sidebar Up (8 posts)

  1. sponauglebl
    Member
    Posted 1 year ago #

    Hi there,

    I am moderately familiar with using CSS and PHP and have gotten myself into a bit of an issue. I was trying to create a new widget and after much ado, loaded the page and my sidebar had moved below my content.

    I have no idea what I did, deleted, moved, etc. I went to validate my code on w3c and it said there was an error on line 155. I have no idea how to find that and edit it...and if that will even fix the problem. I've been through every PHP file and the stylesheet and just don't know.

    Please help! I'm on a bit of a deadline and this has become a huge setback.

    Thank you.

    http://upcavage.com

  2. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    Looks like you have an extra closing </section> tag just above the sidebar div:

    /section>
    
      		</section>
    
    		  	  	<nav id="sidebar">

    See if you can find that in your content for that page.

  3. sponauglebl
    Member
    Posted 1 year ago #

    This seems to be the problem but I cannot locate this code! I've been in every file and the style sheet and just cannot find it. Where should I be looking?

  4. sponauglebl
    Member
    Posted 1 year ago #

    I used the Google Chrome "inspect element" and deleted that extra </section> tag to see what would happen and the sidebar moved up, but my content disappeared entirely...

  5. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    Have you looked in your content for that page? Or in the page template or in the sidebar.php file?

  6. sponauglebl
    Member
    Posted 1 year ago #

    Yes. I have looked in each PHP file I have, the Stylesheet, everything. I cannot find that section of code. I only see it when I use the inspect element on google chrome or the validator on w3c. But even so, when I deleted it on the inspect element it didn't solve my problem because my slideshow disappeared along with my comment box.

  7. Download the theme and do a text editor search in the entire folder if you can't find the extra </section> tag. It's probably at the very bottom of the front page template right above the sidebar call.

    Use the validator, too: [Invalid] Markup Validation of upcavage.com - W3C Markup Validator. Scroll down in the validation report to see line numbers and source code.

  8. sponauglebl
    Member
    Posted 1 year ago #

    Thank you songdogtech!

    For others with the same issue:

    I downloaded my theme files brand new from the website to my desktop. I opened each PHP file and compared it to my old "broken" PHP files located in my FTP client. I then copied the correct code and pasted it into my "broken" file to fix it.

    Although this process seems tedious (And it was) it allowed me to keep all the alterations I made to the theme while fixing the coding issue by using the original theme files.

    Thank you!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags