﻿/**
 * This function is to launch flash click throughs so we don't get popup blockers on external links
 * 
 * @param a_url         This is the url you want to browse to
 * @param a_target         This is the target window you want to go to, supported targets are _blank, _self
 * 
 * @return true
 */
function OpenWindowUrl(a_url, a_target)
{
    var l_blankSearch = new RegExp("blank", "gi");
    var l_selfSearch = new RegExp("self", "gi");
 
    if(a_target.search(l_blankSearch) >=0)
    {
        // This is a blank window open
        window.open(a_url);
    }
    else if(a_target.search(l_selfSearch) >=0)
    {
        // This is a self window open
        window.location.replace(a_url);
    }
    return true;
}