Question: Does anyone know if you can remove head elements on a button click and how to do it with jQuery?

I am trying to get rid of certain script tags from the html head when a button is clicked.
For instance. I have 1 screen view with a slideshow controlled by an external javascript file. When I click on a button "Click to get rid of this elements JS" I want to remove the external javascript path from the HTML Head.

Any ideas. Have been at this thing for a week or so.

Answer: 
You can add an id to a script element then remove that ID:

```
<script type="text/javascript" src="init.js" id="initJs" ></script>

<span id="removeScript"></span>

$('#removeScript').click(function() {
     $('#initJs').remove();
});

```
For remove js file : $("script[src='your.js']").remove();