Example:
<script>
// I want to have the dom element of the script tag that is holding the code that goes here
</script>
If I do:
<script>
alert(this)
</script>
this is the window.
I want to access the script tag itself.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This should find the
<script>elements you have in your page.If you want the one the code is in I think you can do this:
Just curious: what do you want to do with it once you’ve got it?