blog about graphic design, web design and marketing

The D. Drew Design Blog
9
may 09

What I Learned from PHP Today

My place, put quite simply. PHP is a maniac of detail, and like the school marms of yore, PHP has no problem kindly rapping you on the wrist with a ruler should you step out of line. Here's a few things I learned through battered wrists from PHP today:


  • PHP does not like it when you forget that two equal signs is not the same as one. This problem plagued me for a good 45 minutes.
  • PHP's fickle cousin, MySQL, does not like text to come into the database in any interesting or unique way. It probably also likes cauliflower.
  • MySQL also thinks it's hilarious when you forget to specify which ID you're trying to UPDATE in your database, and, instead, wipes your entire database and rewrites it with the same entry. This is why I'm back down to one post. I knew I should've backed up my database... :|
  • I'm not sure I'll ever learn how to use preg_replace with any manner of efficacy. Thank god other people seem to have mastered the art of writing //?*()
  • <UL> will also kill the <P> formatting. I remedy this by adding a <P> tag at the end of the replacing <UL> line (e.g. <UL><P>). Convenient? No.


I like all that I'm learning... now... that I've remedied all of these issues. Like the school children of yore, I'm sure in a few years I'll be telling the new generation of programmers that I once had to write my website without any aid of a robot. A robot that serves margaritas and burgers... Yes...