IE7, xmlhttprequest, and 1223 status code

I’m working on a program that is fairly Ajax heavy right now. Several of the JS routines need to call for XML from the server, and when there is no data to parse I’m sending a 204 header (no content) so that the JS can know there’s no data without having to parse the [...]

JSDoc - Docmentation for JavaScript files

I’ve finally dragged myself, kicking and screaming, into using phpDoc on my PHP files to keep my sanity. But I’ve always been very sparse on my JavaScript documentation. I’ve got what I thought was a good excuse though - those comments have to be downloaded to the visitors machine meaning more time before [...]

Generating element IDs with JavaScript and counters

The code that I posted in my previous post on creating a unique ID in JavaScript is fairly similar to code that’s all over the internet and seemed like it should work. And to be fair, it did work, although with one major problem. If the code runs too quickly it’s possible for [...]

How to generate a unique id in JavaScript

PHP makes it pretty easy to generate a unique it with the uniqid() command. JavaScript doesn’t have that command, but using the getTime() function of the Date object we can do almost the same thing.
PLAIN TEXT
JavaScript:

function uniqid()

    {

    var newDate = new Date;

    return newDate.getTime();

    }

The function returns [...]

XML Parsing Error: junk after document element

Since I had to go through about 20 pages to find the cause of this error, I figured I’d throw up one more with the cause that I found. Hopefully it’ll help somebody spend less time debugging the problem than I had to spend.
I’ve got a PHP script outputting XML that’s called from an [...]