Not necessarily... You don't have to get them by ID. You can get them
by tagname or, with a simple helper, class name.
Or group them, then cycle through... something like
var controls =
document.getElementById("controls").getElementsByTagName("a")
for(var i=0;i<controls.length;i++){
    controls[i].onclick ...

etc.

Onclick you could get the id or href or whatever you need from that
particular link.

It's 2007. There's better ways of doing these things than littering
your html with event handlers.


On Feb 2, 11:02 am, "[EMAIL PROTECTED]"
<[EMAIL PROTECTED]> wrote:
> Hello.
> ahh weekend :)
>
> On Feb 2, 3:30 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
> wrote:
>
> > Why does that hurt? Sure is better than having onclick handlers
> > littering your html all over the place.
>
> Well the hurting thing is that You have to be aware of control id.
> Besides controlling of many <script> tags may be quite hard. And it's
> not elegant at least for me. And one more reason Im not so in love
> with <script> tag is that sometimes someone may insert a function
> (quite complicated) definition inside. Have You ever try to debug such
> function (in mozilla debugger, or MS equivalents)?
>
> Have a nice weekend :)
>
> Regards
> Michal


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to