Fixed It!

0 views
January 22, 2008· Filed Under This blog 

Tags: , , , , , , , , , ,

I wanted to switch the commenting system off on one of my posts, so I did. The only trouble was the side effect. The right hand side bar took umbridge and slid down to beneath the central column, which you are reading now.

After posting on the Wordpress support forums, someone suggested that there was a missing opening or closing <div> - a technical web design thing (divs come in pairs - one opens and then there should be another that closes). Luckily I know what these things are, and, more or less, what they do (div = divider), so I set about hunting down the errant piece of HTML. At first, despite my best efforts, I could not track the blasted thing down. Really annoying, I can tell you.

Well, I’m pleased to say that during a quiet moment today I managed to compare the code used in this site with the original code developed by one Brian Gardener, and, I spotted the error, and corrected it. Now I can turn the comment system off and on and the side bar does not become all grumpy. Something of a relief.

And who was to blame for the error? Yep, you guessed: it was tinkering little old me. I had inserted Google Analytics code and inadvertently erased a <div> tag. Twit. Oh well, you live and learn. I shall be more careful next time.

Still, all the hunting around gave me more of an idea as to how these Wordpress pages are created. Very interesting. Did you know that you are not looking at one HTML page, but four bits of HTML all stitched together courtesy of the magic of PHP? Very clever stuff.

Share:
  • StumbleUpon
  • del.icio.us
  • Digg
  • Facebook
  • Segnalo
  • E-mail this story to a friend!

More Posts From The Same Category:

Comments

2 Responses to “Fixed It!”

  1. Roam2Rome said on January 23rd, 2008 2:45 am

    Aaaa, this would pretty much define how the past 3 weeks have been like for me :)

    I actually decided to seriously tweak or downright invent the CSS and PHP on my site.

    Except that after one extra bit of code my entire blog *poof* disappeared. Who knew that could happen in selfhosted WordPress! Boh! Guess it can.

  2. AlexR said on January 23rd, 2008 12:38 pm

    Nice to hear that I’m not alone!

    I try to avoid tinkerng too much with PHP and CSS, because I know strange things can happen! I don’t know much about PHP, but I do know a little about CSS, so I only tinker with the CSS things I more or less understand - and I add notes to CSS files to help me understand what I have changed - so I can resort to the original functioning version if things go pear shaped!

    If you really want to get into the ‘nuts and bolts’ then the best thing to do is to replicate your Wordpress installation on your own computer - then you can tinker to your hearts content, and if things go wrong, nobody will ever know;-) Do a search for ‘Apache friends’ and you will find a system that installs and sets up everything you need (Apache, MySql, PHP) to run Wordpress on your own PC. Excellent and relatively simple.

    Have fun!

    Alex

Have your say




supernal-hilarious