CSS event:Selectors

What is it?

event:Selectors allow you to apply an event such as mouseover, mouseout, click, et al using a CSS style syntax. It keeps your layers separated and greatly reduces the amount of code you have to write.

気持ち良くてしょうがねえbehaviour.jsをprototype.jsベースでさらにイベントオブジェクトまでCSSスタイルで指定できるようにしたモノ。

ほぅ・・・かしこいなあ。

Making it work

You need to start the event:Selectors before they will do anything:

eventSelectors.start(Rules);

This should either go an an onload event in the head of your document or right before the closing body tag.

でもコレを下のほうに書かなくちゃいけないのはいやだな・・・。コレは必須なのかな?おれの思い違いか?

Comments


Option