How to get only 1 submit button to trigger a function in Jquery?
<p>I have four different types of submit buttons below:</p>

<pre><code>&lt;form id="QandA" action="register.php" method="post"&gt;

&lt;input type='submit' name='submitImageBtn' class='sbtnimage' value='Upload' /&gt;

&lt;input type='submit' name='submitVideoBtn' class='sbtnvideo' value='Upload' /&gt;

&lt;input type='submit' name='submitAudioBtn' class='sbtnaudio' value='Upload' /&gt;

&lt;input id="submitBtn" name="submitDetails" type="submit" value="Submit Details" /&gt;

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

<p>Now I have a function below which is suppose to handle what happens after a submit button is clicked:</p>

<pre><code>    $(function() {
    myClickHandler=function(e)
        {
            if (!validation())
                return false;

            if (!confirm("Are you sure you want to Proceed?" + "\n" ))
                return false;

            $.ajax({
                url: "insertQuestion.php",
                data: $("#QandA").serialize(),
                async: false,
                type: "POST"
            });

            return true;
        };

$('#QandA').submit(myClickHandler);


    });
</code></pre>

<p>Now at the moment all the above submit buttons trigger the event above. I only want the <code>id="submitBtn"</code> submit button to trigger the above function. I don't want the other submit buttons to touch this function. My question is how can I do this?</p>

<p><strong>UPDATE:</strong></p>

<pre><code>$(function() {
$('#submitBtn').click(function(){
myClickHandler=function(e)
    {
        if (!validation())
            return false;

        if (!confirm("Are you sure you want to Proceed?" + "\n" ))
            return false;

        $.ajax({
            url: "insertQuestion.php",
            data: $("#QandA").serialize(),
            async: false,
            type: "POST"
        });

        return true;
    };
});    
});
</code></pre>
