Possible Duplicate:
How may I reference the script tag that loaded the currently-executing script?
I wan't implement this configurations options In a script whit this form
<script src="x.js" attr1="val1" attr2="val2" attr3="val3"></script>
the problem is find the current script tag, and x.js can be in varius paths fold1/x.js
fold1/fold2/x.js
../fold/x.js
etc...
I think that is possible because Dojo framework use this approach.