I’ve been injecting some CSS/Javascript into a prototype (via plugins) and I’ve been targeting the divs with the IDs (#u123 etc.). The problem is if I make a change to the prototype and push to axshare, the IDs sometimes change and I have to inspect element to find out what the new ID is and replace it everywhere. Does anyone know how the IDs are generated?
The only slight fix I have is using variables so I only have to change the ID in one place, at least for my javascript plugin. Is there another workaround for this? Any info into the ID generation would help so I can keep in mind what’ll actually affect the IDs and I could try to avoid upsetting it.
Example setup to provide context:
Plugin 1:
<script type=“text/javascript”>
var headerJs = ‘#u317’;
…
$(headerJs).addClass(“small”);
</script>
Plugin 2:
<style>
#u317.small{
height: 50%;
}
</style>
some dynamic panel OnClick opens link “javascript:void($(headerJs).removeClass(“small”)”
Thanks in advance!