Archive for the ‘Plugin’ Category

Infinite loop with Prototype js v1.5

Wednesday, April 23rd, 2008

The Prototype library in its version 1.5 was quite buggy.
The problem is when you have a fancy old Wordpress plugin (like Lightbox 0.5), you might load Prototype 1.5_pre1 without notice, and it may broke other plugins (like the Commentag one).

If you are in that case, don’t panic.
Just update your Lightbox plugin to its latest version to date (0.6.3, available here)

If you are using another fancy plugin using an old version of Prototype, make sure to update it (Prototype is now at version 1.6.0.2)

Share/Save/Bookmark

Commentag plugin now compatible with Prototype.js lib running in parallel

Monday, April 21st, 2008

Strangely enough, the Commentag plugin was not working on Nellio.com.
It produced some strange javascript outputs.

Digging into the problem showed that jQuery is not a friend of Prototype (two Javascript librairies).
So, I’m now running jQuery in noConflict() mode.

Besides, I also had to change
for (t in tags[])
to something like
for (t=0;t < tags.length;t++)

Because it looks like Prototype is adding some helpers to manipulate arrays which causes a for each loop to actually call these helpers. Which is really bad.

So now, it is all fixed.
Oh, btw, no one has got to update their commentag plugin :-)
If you had the problem and turned off the commentag plugin, just re active it and it will work like a charm.

Don't forget to give us your feedback

Share/Save/Bookmark

Commentag now compatible IE6

Tuesday, April 15th, 2008

It took a bunch of hours but now it is done.
How come can  people still use IE? It is pure rubbish and a real nightmarre for web developpers.

Anyway. I’ve borrowed an old and noisy Dell Inspiron 5100  which runs IE6 and I spent my last evening focusing on making IE6 understands standards.

The most annoying thing is its lack of support of transparent PNG files. I’ve used the excellent script of 24ways which takes advantage of the IE-only functionality of post processing a page using an AlphaFilter.
More info here.

Amongst other  hacks I had to go through, there is to mention that there is a way to specifiy CSS properties which will be only interpreted by IE6.

For example, if you start your CSS property with an underscore (eg. _background: …) then only IE6 will interpret it.

In the same way, if you start with a double slash (eg. // background: …) then all browsers but IEx will interpret it (note: the standard way to put comments in a CSS file is only to use the delimiters /*  …   */ ).

Last but not least, Firefox and Safari both consider a defaut left margin of 0px for <ul> while IE6 does not.
So don’t forget to state
ul {
margin-left:0;
}

It also looks like floating elements do not always have a good presentation under IE6. Sometimes it’s better to put your object with a _position:absolute; (what I did for the commentag logo to make it overlap the main part of the site).

Other useful links to deal with compatibility issues between IEx, Firefox and Safari:

Share/Save/Bookmark