stop function that run with setTimeout
<p>I want stop my function that run with setTimeout and do not show image followed mouse. I want do that with button click, how do that?
my code:</p>

<pre><code>&lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
&lt;head id="Head1" runat="server"&gt;
&lt;title&gt;&lt;/title&gt;
&lt;script type="text/javascript"&gt;
    var trailimage = ["test.gif", 100, 99];
    var offsetfrommouse = [-25, -25];
    var displayduration = 0;
    function truebody() {
        return (!window.opera &amp;&amp; document.compatMode &amp;&amp; document.compatMode != "BackCompat") ? document.documentElement : document.body;
    }
    function hidetrail() {
        var x = document.getElementById("trailimageid").style;
        x.visibility = "hidden";
        document.onmousemove = "";
    }
    function followmouse(e) {
        var xcoord = offsetfrommouse[0];
        var ycoord = offsetfrommouse[1];
        if (typeof e != "undefined") {
            xcoord += e.pageX;
            ycoord += e.pageY;
        }
        else if (typeof window.event != "undefined") {
            xcoord += truebody().scrollLeft + event.clientX;
            ycoord += truebody().scrollTop + event.clientY;
        }
        var x = document.getElementById("trailimageid").style;
        x.left = xcoord + "px";
        x.top = ycoord + "px";            
    }

        alert("obj_selected = true");
        document.onmousemove = followmouse;
        if (displayduration &gt; 0)
            setTimeout("hidetrail()", displayduration * 1000);

&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;form id="form1" runat="server"&gt;

    &lt;img alt="" id="trailimageid" src="Pictures/sides/sides-not-clicked.gif" border="0" style="position: absolute; visibility: visible; left: 0px;
    top: 0px; width: 50px; height: 50px"/&gt;

&lt;/form&gt;
 &lt;/body&gt;
&lt;/html&gt;
</code></pre>
