var domainnums;
var rands;
theDomain = new Array();

domainnums = 1;
theDomain[0] = "un.sharele.cn";

if (domainnums > 1) {
    rands = Math.round(Math.random() * domainnums);
    while (rands > (domainnums - 1)) {
        rands = Math.round(Math.random() * domainnums);
    }
} else { rands = 0; }

if (rands == "") { rands = 0 }
var codedomain = theDomain[rands];


//if (star_userid != '0') {
//    var star_str_url;
//    star_str_url = document.referrer;
//    if ((star_str_url.indexOf("cnxad.com") < 0) && (star_str_url.indexOf("star8.net") < 0)) {
//        if (self != top) {
//            alert('star8.net Warning');
//            top.location = self.location;
//        }
//    }
//}

var xw_encodes = ad_encode;
var xw_widths = 300;
var xw_heights = 240;
var xw_userids =ad_userid;
var xw_subids = ad_subid;
var xw_logos = ad_logo;
var xw_exids = ad_exid;

var ClickUrl = "http://" + codedomain + "/AdCode.aspx?exid=" + xw_exids + "&codeCrt="+ad_f+"&webuserid=" + xw_userids + "&subid=" + xw_subids + "&logo=" + xw_logos + "&exid=" + xw_exids + "&encode=" + xw_encodes + "&keyword=&furl=" + window.location.href;


var ifrm_id = "xw_message";
var div1_id = "div1_xw_net";
var closebtn_id = "closebtn_xw_net";
var xwwh=300;
var xwhg = 240;

document.write('<div id="'+div1_id+'" style="padding: 0; margin: 0; z-index: 999994; right: 0; height: ' + xwhg + 'px; width: ' + xwwh + 'px;">');
document.write('<div onclick="function window.open(){ return false; }" style="margin: 0; padding: 0px 0px 0px 0px; width: '+xwwh+'px; height: '+xwhg +'px;">');

document.writeln('<iframe name="'+ifrm_id+'" src="' + ClickUrl + '" MARGINWIDTH=0 MARGINHEIGHT=0  HSPACE=0 VSPACE=0 FRAMEBORDER=0 SCROLLING=no WIDTH=' + (xwwh-5) + ' HEIGHT=' + (xwhg-5)  + ' allowTransparency="true"></iframe>');

document.write('</div><div style="position: absolute; z-index: 9999999;top: 5px; left: '+(xwwh-60)+'px; width: 52px; font-size: 12px; text-align: right;">');
document.write( '<a id="'+closebtn_id+'" onclick="function window.open(){ return false; }" style="color: #FFF; text-decoration: none; font-size: 12px; cursor: pointer;"> <img src="http://c.kucent.com/F_close.png" alt="Close" style="margin:0; padding:0; width:25px; height:13px;" /></a>');
document.write('</div></div><script type="text/javascript" src="http://un.sharele.cn/ss.js"><\/script>');

