How to retain focus until closed the popup window
<p>how can i retain focus the popuP window? currently it shows the popup window but when i click anywhere outside the popup window it closes the window, what i would like to have is to close only when the user click on close button. here is the <strong><a href="http://jsfiddle.net/abuhamzah/DSa9H/" rel="nofollow">DEMO</a></strong></p>

<pre><code>//html:
    &lt;a id='clickShow' class='a'&gt;Click here&lt;/a&gt; 
    &lt;div id="popupContact" class='divpopup'&gt;
            &lt;a id="popupContactClose"&gt;x&lt;/a&gt;
            &lt;h1&gt;Option Image&lt;/h1&gt;
            test 123
         &lt;/div&gt;
        &lt;div id="backgroundPopup"&gt;&lt;/div&gt;
</code></pre>

<p>//js:</p>

<pre><code>//SETTING UP OUR POPUP
//0 means disabled 1 means enabled
var popupStatus = 0;
function centerPopup(){
    //request data for centering
    var win = {
            height: $(document).height(),
            width: $(document).width()
        },
        pop = {
            height: $("#popupContact").height(),
            width: $("#popupContact").width()
        };
    $("#popupContact").css({
        "position": "fix",
        "top": win.height/2-pop.height/2,
        "left": win.width/2-pop.width/2
    });
    //only need force for IE6    
    $("#backgroundPopup").css({
        "height": win.height
    });   
}
function disablePopup(){
    //disables popup only if it is enabled
    if(popupStatus==1){
        $("#backgroundPopup, #popupContact").fadeOut();
        popupStatus = 0;
    }
}
function loadPopup(id){
    //centering with css
    centerPopup();
    //loads popup only if it is disabled
    if(popupStatus==0){
        $("#backgroundPopup").css("opacity", "0.7").fadeIn();
        $("#popupContact").fadeIn();
        popupStatus = 1;
        getValueOptionImage($(this).attr('id'));
    };
}
function getValueOptionImage(value) {
    $(".option_radio").unbind("change").change(function(e) {
        alert("a ID: " + value + "\nradio Value: " + $(this).val());
    });
}
$(function() {
    $("a").on("click", loadPopup);
    //CLOSING POPUP
    $("#popupContactClose, #backgroundPopup").click(disablePopup);
    //Press Escape event!
    $(document).keypress(function(e){
        if(popupStatus==1 &amp;&amp; e.which==27) disablePopup();
    });
});
</code></pre>
