Excerpts from the Javascript API

November 19, 2004

Programming in Javascript is like trying to hit a moving target. Below are a few excerpts you would expect to find in the non-existent Javascript API. I will leave it as an exercise to identify the methods to which I am referring.

Sometimes this method works, sometimes it doesn't work. Some clients don't even implement this method. The only way to know if the method is active is to try to run it and see if it does anything.
The name of this property is different for just about every client. On some clients, the same name is used for a completely different purpose. Refer to the countless charts that exist on the web to help decifer this situation.
Some runtime environments will causes leaks if calling this method in a particular way since those clients don't implement garbage collection for this type of object.
Some runtimes will implement security restrictions on this method, causing it to fail, but there is no way to know ahead of time which restrictions are being imposed. It depends on the decision of the PR department.
When this method is invoked by the client, it either takes one argument or no arguments. When it takes no arguments, the caller's state must be retrieved from the global scope. However, that object is completely different from the one passed as an argument.
This method returns the dimensions of an object, but often times it returns a value slightly more or slightly less, depending on the client, the rendering mode, and the attributes of the object. In standards compliance mode, this method may even be located on a completely different object. To be sure, handle it conditionally by detecting the client version. However, that is often difficult since some clients will fake their signature. It is usually necessary to test it a couple hundred times before you see the way it actually works.
In some cases, the client intepreter may be disabled entirely. Under this circumstance, it is necessary to handle the problem using a completely different solution.

Posted at 07:46 AM in Javascript | Permalink Icon Permalink | Comment Icon What, no comments?

mozparty2 :: The Firefox Cometh

November 12, 2004

Mozilla Firefox has turned 1.0 and it is time to celebrate! Now, I know all of you are using the fox (cough, cough) because it is the best browser on the planet. And, of course, you are joining in on the battlefield by getting everyone you know to see the light as well. And after all that hard work, there shall be much rejoicing!

As a loyal DuClaw patron and Mozilla Firefox user, I have taken an effort to coordinate a gathering at DuClaw in Arundel Mills on Thursday, Nov 18th, as an official Mozilla Firefox 1.0 party location. DuClaw will be having a seasonal beer release for their award-winning Devil's Milk dark amber barleywine. DuClaw brews the best beer in Maryland, and this beer tops that list. What better way to celebrate the coming of Firefox 1.0 than to pair it with great beer.

If you are in the area, come on by! Oh, and be sure to sport your official firefox paraphernalia!

Update: I am still waiting on my Firefox t-shirts ;( They must be really popular this year.

Posted at 08:48 AM in Open Source | Permalink Icon Permalink | Comment Icon Comments (1)