“Commenting out” code

This is a commentIf you’re using the custom design option with your WordPress (.com) template … you can’t “comment” things out! This was a very unfortunate discovery!

I’d been happily commenting out lines of html and css while I was customising my templates for my hosted (wordpress.org) site. And it worked exactly as I expected. After all, that comment tag, or the slightly different one for css is one of the best things to know about when you’re amending code.

But it wasn’t same for this blog – using wordpress.com. I’d added the custom design option because I wanted to fine tune a few things, and as part of that process, was commenting out css code and then adding it back in. It didn’t even occur to me to check that I could do this!

It took me a little while to realise that anything in the “commented out” css was actually being removed. Deleted. Just not there when I went back to edit some more.  Grrrr!

Lesson here is to absolutely do your edits in an external something, like notepad, or Dreamweaver, even MS Word! Those fine-tuning tweaks can be frustrating to recreate!

If you’ve never come across the comment tag, you can find out more about it at:

Has this ever happened to you?


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s