Search the archives!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Javascript] item.onclick = "alert('foo');";
- From: flavio at economisa.com.br (Flavio Gomes)
- Subject: [Javascript] item.onclick = "alert('foo');";
- Date: Mon Nov 7 09:44:34 2005
Funny same here.. couldn't catch why didnt' worked..
But this worked:
=========================
item.onclick = function () { alert('foo'); };
=========================
Anthony Ettinger escreveu:
>this doesn't seem to work:
>
>var item = document.getElementById('foo');
>item.onclick = "alert('foo');";
>
>http://developer.mozilla.org/en/docs/DOM:element.onclick
>
>Anthony Ettinger
>ph: (408) 656-2473
>web: http://www.apwebdesign.com
>_______________________________________________
>Javascript mailing list
>Javascript@xxxxxxxxxx
>https://lists.LaTech.edu/mailman/listinfo/javascript
>
>
--
Flavio Gomes
flavio@xxxxxxxxxxxxxxxx
- References:
- [Javascript] item.onclick = "alert('foo');";
- From: Anthony Ettinger
- [Javascript] item.onclick = "alert('foo');";
- Prev by Date: [Javascript] item.onclick = "alert('foo');";
- Next by Date: [Javascript] item.onclick = "alert('foo');";
- Previous by thread: [Javascript] item.onclick = "alert('foo');";
- Next by thread: [Javascript] item.onclick = "alert('foo');";
- Index(es):