Pathfinder Blog
Topic Archive: WordPress

Formatting quoted code in blog posts: CSS2.1 white-space: pre-wrap

When migrating our blog posts from TypePad to WordPress, chunks of code presented the biggest problem. There was a lot of variation in how individual authors had marked up their code samples. Then there was the junk markup TypePad had inserted, of its own accord, inside <pre> and <blockquote> elements. In the end, I had get my hands dirty inside individual posts in WordPress. For future posts, however, we'll be standardizing our markup patterns and using CSS to style code quotes consistently. We're still working the kinks out of our stylesheets, so please bear with us when reading older posts.

In the meantime, I stumbled upon an informative post by Lim Chee Aun that offers a one-size-fits-all solution for implementing the CSS 2.1 "white-space: pre-wrap" declaration in today's user-agents. If you're not familiar with "white-sace: pre-wrap," it's a way to honor whitespace and line breaks within preformatted text, yet still allow individual lines to wrap when they reach the edge of their enclosing container. In short, it provides the browser equivalent of the "soft wrap text" option in your favorite IDE or text editor - which in many cases looks better than using "overflow: auto" to create an internal scrollbar on the container.

Continue reading »

Topics: , ,

WordPress sucks, but it doesn’t matter

It was with great amusement that I read PHP Sucks, But It Doesn't Matter, a recent post from Jeff Atwood's Coding Horror. Here's an excerpt (emphasis his):

Some of the largest sites on the internet -- sites you probably interact with on a daily basis -- are written in PHP. If PHP sucks so profoundly, why is it powering so much of the internet?

The only conclusion I can draw is that building a compelling application is far more important than choice of language. While PHP wouldn't be my choice, and if pressed, I might argue that it should never be the choice for any rational human being sitting in front of a computer, I can't argue with the results.

WordPress for Dummies

With all my recent work on the Pathfinder blog migration, I've been getting to to know WordPress - and, by extension, PHP - pretty well. Now that the experience is (mostly) over, I've got a few observations about WordPress:

  • It sucks.
  • Its PHP foundation contributes to its suckiness.
  • If you're a developer, it doesn't suck nearly as bad as other blogging platforms.

Let me elaborate.

Continue reading »

Topics: ,

About Pathfinder

  • We design and build extraordinary applications for companies looking to make the next great idea a reality.
  • learn more

Topics

WordPress

Comments about this site: info@pathf.com