'coding' Category
-
Feb182009
Be Careful parsing your URL string with Javascript
…so I know you’ve looked around the net for a good method to parse URL variables with javascript, and I’m sure that you’ve found some elegant method that looks something like: function parseLocation() { var turl = window.location.search; ar = turl.split(‘&’); var b = {}; for (var i = 0; i < ar.length; i++) { […]
-
Oct202008
using Javascript to refresh an image without a cache-busting parameter
…say you’re using Javascript to reload an image periodically, say, every 60 seconds, and the image never refreshes. If you look for help across the webrent a car bulgaria (as undoubtedly you have, since you’re here now, right?) you’ll find a) A bunch of people telling you to tag on a url param that’s a […]
-
Aug062008
Dear Objective C
It’s called “dot notation“, and it works really well. You should check it out.
-
Jul022008
Stupid IE6 and its iframe cookie idiocy needs a throat punch
…so let’s say you have a site, that has two versions, a.throat-punch.com and b.throat-punch.com. And Apache uses a cookie to determine which version you should be viewing, and sends a 302 redirect if you’re on the wrong domain. Now let’s say you want to access a page on this site from an <iframe> from an […]
-
May162008
seriously, wordpress, WTF?
It’s not bad enough that I had to turn off all non-anonymous commenting because of the flood of spam I was getting, but now I get another google-banning for people injecting code into my posts? If I had a nickel for every time this has happened, I’d have like 10 cents by now! Security this […]
-
Feb152008
Elegant little PHP JSON encoder
update: Jay Williams has flushed this out to be a lot more useful. Check out his rendition here. …so I wrote (what I think is a) clever little function (well, two functions) to take a complex php variable and turn it into a json-ized string, ready to be passed back to javascript. It works on […]
-
Jun222007
Dear Flash Web Developers
I know you like to show off your flash-movie-making skills. I know it’s tons of fun to make images fade in and out, and to make text scroll across the screen. I know this kind of stuff makes your clients pop like 1,000 boners and fall over themselves to give you more work. But you […]