October 27, 2009

Some Notes on the Blog

I like to have well-formed and valid code when I use XHTML. This entails things like closing all of your tags (e.g., <p>your paragraph</p>). It also involves putting all of your text inside the right types of tags. If you want to confirm my obsession with this, take a look at the bottom of any page on Brown Freethought's site. You'll find a links to XHTML and CSS validation services in the footer. Click on one and you'll see that the code is XHTML 1.0 Strict (except for one page that I used Transitional on) and passes with flying colors.

So far, I haven't been pleased with how Blogger handles tags. This is mainly due to the fact that it doesn't. Rather than enclosing the paragraphs you write in paragraph tags, it leaves everything out in the open with line breaks (<br />) to differentiate the paragraphs. (Writing text outside of tags is a sin!) To facilitate this, Blogger comes has the following default option:

single hard-returns entered in the Post Editor will be replaced with single <br /> tags in your blog, and two hard-returns will be replaced with two tags (<br /><br />).

I prefer to write my posts in the actual code rather than the WYSIWYG editor because I like to have a greater degree of control over formatting (take a look and you'll find everything wrapped up in nice pretty paragraph tags). This Blogger option adds line breaks where I don't want them without my consent, so I decided to turn it off. I don't know if this effects people using the WYUSIWYG editor, but when I turned it off, I had to go back and change things in previous posts to restore paragraphs. If you are having problems with this and are now publishing posts with all of your paragraphs running together, I can change it back to the default.

I encourage everyone to use proper XHTML or XML, but if you're lazy or don't know these languages, creating your tagless monstrosities is perfectly fine by me. The worse that will happen is that I will think less of you as a human being.

No comments:

Post a Comment