var mx_DuplUser_FormElem = null;

//----------------------------------------------------------

function mx_DuplUser_Initialize()
{
    var i, s;

    for (i=0; i<document.forms.length; i++) {
        s = document.forms[i].action;
        if (s.indexOf("login.php?do=login") >= 0 && s.indexOf("..") < 0)
            break;
    }
    if (i >= document.forms.length)
        return null;
    if (typeof(window.opera) == 'undefined' &&
            navigator.userAgent.indexOf('MSIE')>=0) {
        mx_DuplUser_FormElem = document.createElement('<input name="mxdplusr1_hashcode"/>');
    }
    else {
        mx_DuplUser_FormElem = document.createElement('input');
        mx_DuplUser_FormElem.setAttribute("name", "mxdplusr1_hashcode");
    }
    mx_DuplUser_FormElem.setAttribute("type", "hidden");
    mx_DuplUser_FormElem.setAttribute("value", "");
    document.forms[i].appendChild(mx_DuplUser_FormElem);
    document.writeln('<div id="div_mx_DuplUserCookie" style="display:block">');
    document.writeln('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" name="mx_DuplUser_" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="1" height="1" id="mx_DuplUser_" align="middle">');
    document.writeln('<param name="allowScriptAccess" value="sameDomain" />');
    document.writeln('<param name="movie" value="clientscript/mxCookieMovie.swf" />');
    document.writeln('<param name="quality" value="high" />');
    document.writeln('<param name="bgcolor" value="#0000ff" />');
    document.writeln('<embed src="clientscript/mxCookieMovie.swf" name="mx_DuplUser_" quality="high" bgcolor="#0000ff" width="1" height="1" id="mx_DuplUser_" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
    document.writeln('</object></div>');
    return;
}

function myCookieCallback(args)
{
    if (mx_DuplUser_FormElem != null)
        mx_DuplUser_FormElem.setAttribute("value", args);
    return;
}
