How to make 2 condition in button clicked jquery
<p>Hello is that possible to make two condition from 1 button clicked?</p>

<pre><code>if(unable == 4) {
    $("#formitem").submit(function () {
        $("#order_4").appendTo("body");
        var message = "&lt;?=$message_change_location?&gt;";
        var resotid = &lt;?=$restaurant_info["restaurant_id"]?&gt;;
        var restoname = "&lt;?=$restaurant_info["restaurant_name"]?&gt;";
        var restomenu = "&lt;?=$restaurant_menu?&gt;";
        var postal = "&lt;?=$postal?&gt;";
        var delivery_no = "&lt;?=$delivery_no?&gt;"
        jQuery.ajax({
            type: "GET",
            url: "/ajax/order_unable",
            dataType: 'html',
            data: {
                message_change_location: message,
                restid: resotid,
                restname: restoname,
                restmenu: restomenu,
                postal: postal,
                delivery_no: delivery_no,
            },
            success: function (res) {
                $("#order_4_show").html(res);
                $("#order_4").modal("show");
            }

        });
        return false;
    });
 }else if($("#second_notif") == "show"){
            $("#formitem").submit(function () {
                alert("asdf");
        });
</code></pre>

<p>I want to make a condition if <code>second_notif</code> is showed, than if i click <code>$("#formitem")</code> for the second times will show the alert. The first click will show  pop up windows, and there is not any problem here.</p>

<p>in the pop up windows there is a script to show the <code>second_notif</code>, with this following code :</p>

<pre><code>&lt;script&gt;
$(document).ready(function() {
    $("#change_location_2").click(function () {
        $(".vendor-heading").hide();
        $(".location-header").hide();
        $("#order_4").modal("hide");
        $("#second_notif").show();
        return true;
    });
});

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

<p>and there in same page on where to show the pop up windows there is a code to show the <code>second_notif</code> too :</p>

<pre><code>$("#change_location").click(function(){
    $(".vendor-heading").hide();
    $(".location-header").hide();
    $("#second_notif").show();
    return true;
});
</code></pre>

<p>here is the view for the <code>second_notif</code> :</p>

<pre><code>&lt;div id="second_notif" style="display:none;"&gt;
     &lt;?php $this-&gt;load-&gt;view('MAIN/'.country_code.'/search');?&gt;
&lt;/div&gt;
</code></pre>

<p>I can show the pop up windows, and show the <code>second_notif</code> when i clicked <code>formitem</code> button, but when the <code>second_notif</code> has been showed and if i clicked the same button again, why i cant show the alert?
guys can you help me how to show the alert?</p>

<p>p.s alert is not my goal, i will change the alert to other view 
please help me guys, thank you (:</p>