Is it bad practice to assign a css class for the sole purpose of finding it with jQuery?
Posted
by user187305
on Stack Overflow
See other posts from Stack Overflow
or by user187305
Published on 2010-05-11T20:29:29Z
Indexed on
2010/05/11
20:34 UTC
Read the original article
Hit count: 213
I'm using ASP.NET, not the newest one with that clientIdMode stuff. So, the control ids are generated and funky.
There are lots of ways of passing ids around, but lately I've been assigning a 'fake' css class to the control I'm interested in. Then in a js file I use jQuery to find the control.
Is this bad practice? It seems a lot like the ajaxControlToolkit's behaviorId to me... Is the behaviorId bad practice as well?
© Stack Overflow or respective owner