﻿/*
 *  SFS JavaScript framework, version 1.0.0
 *  FileName SFS.JS
 *  Copyright (c) 2008 Chuxuewen
 *  Date: 2008-09-24
 *  For details, see the Prototype web site: http://www.sfs-jfm.cn/
 *  
 *--------------------------------------------------------------------------*/
function Namespace (Name) {
    if (Name == "") 
        return window;
    return create(window, Name.split("."));
    function create(objs, names) {
        var name = names.shift();
        if ((/[^a-zA-Z0-9\_-]/).test(name) || !(/[a-zA-Z]/).test(name)) 
            throw new Error("声明命名空间名不正确!");
        if (!objs[name]) {
            objs[name] = {  };
            objs[name].sfsNamespaceMark = true;
        }
        else if (typeof(obj) == "object" && !(obj.constructor === Array) && !(obj.nodeType == 1)) 
            return; //throw new Error('"' + name + '"重复声明!');
		if (names.length != 0) 
		    return create(objs[name], names);
        else 
            return objs[name];
    }
}

function Class (name, obj, base) {
    var indexOf = name.lastIndexOf(".");
    var space = Namespace(name.substr(0, indexOf));
    var cname = name.substr(indexOf + 1);
    if (name.match(/[^a-zA-Z0-9\._-]/) || !name.match(/[a-zA-Z]/))
        throw new Error("声明类型名不正确!");
    if (space[cname]) 
        return; //throw new Error('"' + name + '"类型重复声明!');
    var klass = function () {
      var base_, args = Array.toArray(arguments);
      if (base) {
          base_ = new base("inheritance");
          for (var i in base_) {
              if (!this[i]) {
                  this[i] = base_[i];
              }
          }
      }
      if (args[0] != "inheritance") { 
          this.GUID = name.replace(/\./gm, "_") + "_" + Math.round(Math.random() * 10000000000);
          this[cname].apply(this, args);
          Class.objects[this.GUID] = klass.objects[this.GUID] = this;
      }
    }
    for (var i in obj) {
        if (typeof obj[i] == "function") {
            var argus = obj[i].argumentNames();
            switch (argus[0]) {
                case "___methodStatic": klass[i] = obj[i]; break;
                case "___methodPublic": klass.prototype[i] = obj[i]; break;
                case "___attributeStatic": klass[i] = obj[i](); break;
                case "___attributePublic": klass.prototype[i] = obj[i](); break;
                default: klass.prototype[i] = obj[i];
            }
        }
        else 
            klass.prototype[i] = obj[i];
    }
    if (!klass.prototype[cname])
        klass.prototype[cname] = function () { };
    klass.prototype.destroy = function () {
        Class.objects[this.GUID] = klass.objects[this.GUID] = null;
        for (var i in this) 
            this[i] = null;
    }
    klass.objects = {  };
    klass.sfsClassMark = true;
    return space[cname] = klass;
}

Class.objects = {  };

function staticClass (name, obj, base) {
    var indexOf = name.lastIndexOf(".");
    var space = Namespace(name.substr(0, indexOf));
    var cname = name.substr(indexOf + 1);
    if ((/[^a-zA-Z0-9\._-]/).test(name) || !(/[a-zA-Z]/).test(name))
        throw new Error("声明类型名不正确!");
    if (space[cname]) 
        return; //throw new Error('"' + name + '"类型重复声明!');
    var staticObj = space[cname] = {  };
    staticObj.sfsStaticClassMark = true;
    extend(staticObj, base);
    extend(staticObj, obj);
    if (!staticObj[cname]) 
        staticObj[cname] = function () {  }
    staticObj[cname]();
}

function method () {
    var __methods = Array.toArray(arguments);
    var isStatic = __methods[0] == "static" ? (__methods.shift() == "static") : false;
    if (__methods.length == 0) 
        throw new Error("声明方法出现错误!");
    else {
        return isStatic ? (function (___methodStatic) {
            var args = Array.toArray(arguments);
            for (var i = 0; i < __methods.length; i++) {
                if (__methods[i].argumentNames().length == args.length) {
                    return __methods[i].apply(null, args);
                }
            }
            return __methods[0].apply(null, args);
        }) :
        (function (___methodPublic) {
            var args = Array.toArray(arguments);
            for (var i = 0; i < __methods.length; i++) {
                if (__methods[i].argumentNames().length == args.length) {
                    return __methods[i].apply(this, args);
                }
            }
            return __methods[0].apply(this, args);
        })
    }
}

function attribute () {
    var args = Array.toArray(arguments);
    var isStatic = args[0] == "static" ? (args.shift() == "static") : false;
    return isStatic ? (function (___attributeStatic) {
        return args[0].apply(null);
    }) :
    (function (___attributePublic) {
        return args[0].apply(this);
    })
}

function extend (obj, source) {
    for (var property in source) {	
		try{
	        obj[property] = source[property];
		}catch(e){}
	}
    return obj;
}

Array.toArray = function (iterable) {
  if (!iterable) 
      return [];
  if (iterable.toArray) 
      return iterable.toArray();
  var length = iterable.length, results = new Array(length);
  while (length--) 
      results[length] = iterable[length];
  return results;
}

extend(Function.prototype,{argumentNames:function(){var $=this.toString().match(/^[\s\(]*function[^(]*\((.*?)\)/)[1].replace(/ /gm,"").split(",");return $.length==1&&!$[0]?[]:$},bind:function(){if(arguments.length<2&&arguments[0]===undefined)return this;var _=this,A=Array.toArray(arguments),$=A.shift();return function(){return _.apply($,A.concat(Array.toArray(arguments)))}},bindAsEventListener:function(){var _=this,A=Array.toArray(arguments),$=A.shift();return function(B){return _.apply($,[B||window.event].concat(A))}},curry:function(){if(!arguments.length)return this;var $=this,_=Array.toArray(arguments);return function(){return $.apply(this,_.concat(Array.toArray(arguments)))}},delay:function(){var _=this,A=Array.toArray(arguments),$=A.shift()*1000;return window.setTimeout(function(){return _.apply(_,A)},$)},defer:function(){var $=this,_=Array.toArray(arguments);return $.delay.apply($,[0.01].concat(_))},wrap:function(_){var $=this;return function(){return _.apply(this,[$.bind(this)].concat(Array.toArray(arguments)))}},methodize:function(){if(this._methodized)return this._methodized;var $=this;return this._methodized=function(){return $.apply(null,[this].concat(Array.toArray(arguments)))}}});extend(Array.prototype,{remove:function($){if(isNaN($)||$>this.length)return false;this.splice($,1);return this},add:function(_){for(var $=0;$<this.length;$++)if(this[$]===_&&this[$]==_)return;this.push(_)},removeKey:method(function($){for(var _=0;_<this.length;_++)if(this[_]===$||this[_]==$)return this.remove(_)},function($,A){for(var _=0;_<this.length;_++)if(this[_][A]===$||this[_][A]==$)return this.remove(_)}),cut:function($){var A=new Array($);for(var _=0;_<$;_++)A[_]=this.shift();return A},replace:function(_,A){for(var $=0;$<this.length;$++)if(this[$]===_)this[$]=A},ToString:method(function($){return this.toString().replace(/,/gm,$)},Array.prototype.toString),each:function(_){for(var $=0;$<this.length;$++)_(this[$],$,this)}});extend(String.prototype,{Match:function(_){var C,B=new Array(),A=null;if(typeof _=="string")C=new RegExp(_,"gm");else C=_;for(var $=0;true;$++){A=C.exec(this);if(A!=null)B[$]=A;else return B}},test:function($){return this.Match($).length!=0},count:function(){var _=0;for(var $=0;$<this.length;$++)if(this.charCodeAt($)>255)_+=2;else _++;return _},trim:function(){return this.replace(/^\s+|\s+$/gm,"")},blank:function(){return/^\s*$/.test(this)},stripScripts:function(){return this.replace(/<script[^>]*>([\S\s]*?)<\/script>/img,"")},stripTags:function(){return this.replace(/<\/?[^>]+>/gi,"")},toArray:function(){return this.split("")},times:function($){return $<1?"":new Array($+1).join(this)},isJSON:function(){if(this.substr(0,1).match(/[\[\{]/)&&this.substr(this.length-1,1).match(/[\]\}]/)){var _=[],A;for(var $=0;$<this.length;$++){A=this.substr($,1);switch(A){case"[":case"{":_.push(A);continue;case"]":if(_.pop()!="[")return false;continue;case"}":if(_.pop()!="{")return false;continue}}if(_.length==0)return true}return false},isHTML:function(){return this.Match(/\<.+\>.*\<\/.+\>/img).length>0},evalJSON:function(sanitize){var j;function walk(_,B){var $,A;if(B&&typeof B==="object")for($ in B)if(Object.prototype.hasOwnProperty.apply(B,[$])){A=walk($,B[$]);if(A!==undefined)B[$]=A}return filter(_,B)}var tStr=this.replace(/\\./g,"@").replace(/(new Date\(.+\))/g,"").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(:?[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"");if((/^[\],:{}\s]*$/).test(tStr)){j=eval("("+this+")");return typeof filter==="function"?walk("",j):j}return tStr;throw new SyntaxError("evalJSON\u8f6c\u6362\u51fa\u9519")},eval:function(){function _eval(x){if(x.match(/\s+/)){s=x.trim(),ind=s.indexOf(" ");he=s.substr(0,ind),re=s.substr(ind+1);switch(he){case("int"):return parseInt(re);case("float"):return parseFloat(re);case("bool"):return(re=="true"?true:false);case("string"):return re.toString();case("element"):return select(re);case("json"):return x.trim().replace(/json\s+/gm,"").evalJSON();case("object"):return re=="null"?null:eval(re);default:throw new Error("String.eval\u8f6c\u6362\u51fa\u9519")}}}if(this.isJSON())return this.evalJSON();var m=this.match(/,/),i=0,l=[];if(m||this.match(/\s/)==" "){while(m){var sub=this.substr(i,m.index).trim();i+=m.index+1;if(sub.substr(0,4)!="json")l.push(_eval(sub));else{while(!sub.replace(/json\s+/gm,"").isJSON()){var str=this.substr(i),k=str.match(/,/);if(k){sub+=","+this.substr(i,k.index);i+=k.index+1}else if((sub+","+str).replace(/json\s+/gm,"").isJSON()){l.push(_eval(sub+","+str));return l.length<2?l[0]:l}else throw new Error("String.eval\u8f6c\u6362\u51fa\u9519")}l.push(_eval(sub))}m=this.substr(i).match(/,/)}if(this.substr(i).trim()!="")l.push(_eval(this.substr(i)));if(l.length!=0)return l.length<2?l[0]:l}try{return eval(this.toString())}catch(ex){return undefined}},verify:function(A){if(A.Null!=null&&this=="")return false;if(A.Law!=null&&this.Match(/['"<>\\\/|&!]/gm).length!=0)return false;if(A.Min!=null&&this.count()<A.Min)return false;if(A.Max!=null&&this.count()>A.Max)return false;if(A.Email!=null&&this.Match(/\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/gm).length==0)return false;if(A.Url!=null&&this.Match(/^(http\:\/\/){0,1}[A-Za-z0-9_-]+(\.[A-Za-z0-9-_]+)+\/{0,1}(\/[A_Za-z0-9-_]+)*\/{0,1}([A-Za-z0-9-_]+\.[A-Za-z0-9-_]+){0,1}(\?[A-Za-z0-9-_&=]+){0,1}$/gm).length==0)return false;if(A.Fig!=null&&this.Match(/[^0-9]/gm).length!=0)return false;if(A.IsLetter!=null&&this.Match(/[^a-zA-Z]/gm).length!=0)return false;if(A.IsLetterDigit!=null&&this.Match(/[^0-9a-zA-Z]/gm).length!=0)return false;if(A.Letter!=null&&this.Match(/[a-zA-Z]/gm).length==0)return false;if(A.Digit!=null&&this.Match(/[0-9]/gm).length==0)return false;if(A.isNorm!=null&&this.Match(/[^0-9a-zA-Z_]/gm).length!=0)return false;if(A.Money!=null&&!this.test(/^[0-9]+(\.[0-9]{1,2})?$/gim))return false;if(A.Symbol!=null){len=this.Match(/[^a-z0-9\u4e00-\u9fa5]/igm).length;if(A.Symbol==false&&len!=0)return false}if(A.Space!=null){len=this.Match(/ |    /gm).length;if(A.Space==false&&len!=0)return false}if(A.dMax!=null)if(this.count()>A.dNull)return false;if(A.Mobile==true){var $=/^(?:13\d|15\d|18[8|9])\d{8}$/;if(!$.test(this))return false}if(A.Phone==true){var _=/^(([0\+]\d{2,3}-?)?(0\d{2,3})-?)(\d{7,8})(-(\d{3,}))?$/;if(!RegTel.test(this))return false}return true},truncate:function(A,$){A=A||30;$=$===undefined?"...":$;var B=this.toArray(),C=0,D="";for(var _=0;_<B.length;_++){C+=B[_].count();if(C<=A)D+=B[_];else return String(D+$)}return String(D)},append:method(function($){return this+$},function(_,$){if(this.length>0)return this.append($).append(_);else return this.append(_)})});extend(Date.prototype,{toJSON:function(){return"\""+this.getUTCFullYear()+"-"+(this.getUTCMonth()+1).toPaddedString(2)+"-"+this.getUTCDate().toPaddedString(2)+"T"+this.getUTCHours().toPaddedString(2)+":"+this.getUTCMinutes().toPaddedString(2)+":"+this.getUTCSeconds().toPaddedString(2)+"Z\""}});staticClass("sfs",{version:"1.0.0",browser:{IE:!!(window.attachEvent&&!window.opera),Opera:!!window.opera,WebKit:navigator.userAgent.indexOf("AppleWebKit/")>-1,Gecko:navigator.userAgent.indexOf("Gecko")>-1&&navigator.userAgent.indexOf("KHTML")==-1,MobileSafari:!!navigator.userAgent.match(/Apple.*Mobile.*Safari/),version:null},tagsName:{block:"ADDRESS,BLOCKQUOTE,BODY,CENTER,COL,COLGROUP,DD,DIR,DIV,DL,DT,"+"FIELDSET,FORM,FRAME,HN,HR,IFRAME,LEGEND,LISTING,INPUT,SELECT,"+"MARQUEE,MENU,OL,P,PLAINTEXT,PRE,TABLE,TD,TH,TR,UL,XMP,",list:"LI,",inline:"SPAN,A,SCRIPT,LINK,"},nullFunction:function(){},sfs:function(){this.version=this.browser.IE?navigator.appVersion.match(/MSIE[^;]+/g)[0].replace(/MSIE\s+/g,""):navigator.appVersion.match(/[^\s]+/)[0]},toJSON:function(A,E){var B={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r","\"":"\\\"","\\":"\\\\","'":"''"},D,$,_,F,G,C=/["\\\x00-\x1f\x7f-\x9f']/g;switch(typeof A){case"string":return(C.test(A)?"\""+A.replace(C,function($){var _=B[$];if(_)return _;_=$.charCodeAt();return"\\u00"+Math.floor(_/16).toString(16)+(_%16).toString(16)})+"\"":"\""+A+"\"");case"number":return isFinite(A)?String(A):"null";break;case"boolean":return A.toString();break;case"null":return String(A);break;case"object":if(!A)return"null";if(typeof A.getDate==="function")return sfs.toJSON(A.toString());D=[];if(typeof A.length==="number"&&!(A.propertyIsEnumerable("length"))){F=A.length;for($=0;$<F;$+=1)D.push(sfs.toJSON(A[$],E)||"null");return"["+D.join(",")+"]"}if(E){F=E.length;for($=0;$<F;$+=1){_=E[$];if(typeof _==="string"){G=sfs.toJSON(A[_],E);if(G)D.push(sfs.toJSON(_)+":"+G)}}}else for(_ in A)if(typeof _==="string"){G=sfs.toJSON(A[_],E);if(G)D.push(sfs.toJSON(_)+":"+G)}return"{"+D.join(",")+"}";break}},keys:function(_){var $=[];for(var A in _)$.push(A);return $},values:function($){var A=[];for(var _ in $)A.push($[_]);return A},clone:function($){return this.toJSON($).evalJSON()},isElement:function($){return $&&$.nodeType==1},isArray:function($){return $&&$.constructor===Array},isFunction:function($){return typeof $=="function"},isObject:function($){return typeof $=="object"},isString:function($){return typeof $=="string"},isNumber:function($){return typeof $=="number"},isUndefined:function($){return typeof $=="undefined"},isBoolean:function($){return typeof $=="boolean"},isNamespace:function($){if($.sfsNamespaceMark)return true;return false},isType:function($){if($.sfsClassMark)return true;return false},isStaticType:function($){if($.sfsStaticClassMark)return true;return false},isObjectValues:function(_,A){for(var $ in _)if(_[$]===A)return true;return false},removeObjectValues:function(_,A){var B={};if(sfs.isFunction(A)){for(var $ in _)if(_[$]!==A)B[$]=_[$];else _[$]=null}else for($ in _)if(_[$]!==_[A])B[$]=_[$];else _[A]=null;return B},random:function($){return Math.round(Math.random()*$)}});staticClass("sfs.element",{element:function(){window.select=this.select.bind(this)},select:function(F){if(!F)return;function G($,A){for(var _ in source){try{if($[_]==undefined)$[_]=source[_]}catch(B){}}return $}if(arguments.length>1){for(var E=1,C=[],_=arguments.length;E<_;E++)C=C.concat(this.select(arguments[E])||[]);return C.length>1?extend(C,sfs.elements):C[0]}var B=this.tagName?this:document;if(sfs.isString(F))if(F.isHTML()){var J=this.select(document.createElement("DIV"));J.update(F);J=J.sub(0);if(this.tagName)this.addSub(J);return J}else{var D=F.split(/\s+/),K=D.shift();if(K.substr(0,1)=="#"){F=document.getElementById(K.substr(1));if(!F)return;F=this.select(F);if(D.length!=0)return F.select(D.ToString(" "));else return F}else if(K.substr(0,1)=="."){var I=B.getElementsByTagName("*"),A=K.substr(1),C=[],L;for(E=0;E<I.length;E++)if(A==I[E].className){L=this.select(I[E]);if(D.length!=0)L=L.select(D.ToString(" "));if(L)C.push(L)}return C.length<2?C[0]:extend(C,sfs.elements)}else if(K.substr(0,1)=="$"){var I=B.getElementsByTagName("*"),K=K.substr(1),C={},$;for(var E=0,H=0;E<I.length;E++){$=I[E].getAttribute(K);if($){C[$]=this.select(I[E]);H++}}return H==0?undefined:C}else{I=B.getElementsByTagName(K),C=[],L;for(E=0;E<I.length;E++){L=this.select(I[E]);if(D.length!=0)L=L.select(D.ToString(" "));if(L)C.push(L)}return C.length<2?C[0]:extend(C,sfs.elements)}}if(!F.element)for(E in sfs.element)if(E!="sfsStaticClassMark"){try{F[E]=sfs.element[E]}catch(L){}}return F},visible:function(){return this.style.display!="none"},toggle:function(){this[this.visible()?"hide":"show"]()},hide:function(){this.style.display="none"},show:function(){var $=this.tagName;if(sfs.tagsName.block.Match($+",").length!=0)this.style.display="block";else if(sfs.tagsName.list.Match($+",").length!=0)this.style.display="list-item";else this.style.display="inline"},update:function($){$=$==null?"":$.toString();this.innerHTML=$.stripScripts()},cons:function(){return this.innerHTML},parent:method(function(){return this.select(this.parentNode)},function(A){var _=this;for(var $=0;$<A;$++)_=_.parentNode;return select(_)}),subs:function(){var _=this.childNodes,A=[];for(var $=0;$<_.length;$++)if(!_[$].nodeValue)A.push(this.select(_[$]));if(A.length==0)return extend([],sfs.elements);if(A.length==1)return extend([A[0]],sfs.elements);return A},Length:function(){var A=this.childNodes;for(var $=0,_=0;$<A.length;$++)if(!A[$].nodeValue)_++;return _},sub:function($){var _=this.subs();return _[$]},indexOf:function(){var _=this.parent().subs();for(var $=0;$<_.length;$++)if(this===_[$])return $},sibling:function(A){var $=this.indexOf()+A,_=this.parent().subs();if($<0)return _[0];else if($>=_.length)return _[_.length-1];else return _[$]},remove:function(){this.parent().removeChild(this)},removeSibling:function($){this.sibling($).remove()},removeSub:function($){this.sub($).remove()},insertSibling:function(A,B){if(B>=1){var $=this.indexOf(),_=this.parent().Length();if(_<$+B+1)this.parent().addSub(A);else this.parent().insertBefore(A,this.sibling(B))}else if(B<=-1)this.parent().insertBefore(A,this.sibling(B+1));else throw new Error("\u8981\u63d2\u5165\u7684\u4f4d\u7f6e\u4e0d\u80fd\u4e3a\u7a7a\u6216\u96f6!")},addSub:function(A,$){var _=this.subs();if($==null||$>_.length-1)this.appendChild(A);else this.insertBefore(A,_[$])},addSubs:function(A){var _=A.subs();for(var $=0;$<_.length;$++)this.addSub(_[$])},Width:method(function($){this.style.width=$+"px"},function(){return this.clientWidth}),Height:method(function($){this.style.height=$+"px"},function(){return this.clientHeight}),x:method(function($){this.style.left=$+"px"},function(){var $=this.style.left;return parseInt($.substr(0,$.length-2))}),y:method(function($){this.style.top=$+"px"},function(){var $=this.style.top;return parseInt($.substr(0,$.length-2))}),z:method(function($){this.style.zIndex=$},function(){return this.style.zIndex}),alpha:method(function($){if(this.style.zoom=="")this.style.zoom=1;if(sfs.isString(this.style.MozOpacity))this.style.MozOpacity=$/100;else this.style.filter="alpha(opacity="+$+")"},function(){return sfs.isString(this.style.MozOpacity)?(this.style.MozOpacity*100):(parseInt(this.style.filter.match(/opacity\s*=\s*[0-9]+/)[0].replace(/Opacity=/i,"")))}),background:function($){if($.match(/\.png/img))if(parseFloat(sfs.browser.version)<=6){this.style.backgroundImage="none";this.style.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\""+$+"\", sizingMethod=\"crop\")"}else this.style.backgroundImage="url("+$+")"},Class:method(function(_){if(this.style.removeAttribute){for(var $ in this.style)this.style.removeAttribute($)}else for($ in this.style){try{if($!="length"&&$!="parentRule")this.style[$]=null}catch(A){}}this.className=_},function(){return this.className}),Style:method(function(_){for(var $ in _)this.style[$]=_[$]},function(){var _={};for(var $ in this.style)_[$]=this.style[$];return _}),ainOnClass:function(A,_,$){this.addEvent("mouseover",this.Class.bind(this,_),"ainOnClass_Over");this.addEvent("mousedown",this.Class.bind(this,$),"ainOnClass_Down");this.addEvent("mouseup",this.Class.bind(this,_),"ainOnClass_Up");this.addEvent("mouseout",this.Class.bind(this,A),"ainOnClass_Out");this.Class(A)},cancelBubble:function($){if($)this.cb=sfs.nullFunction;else this.cb=undefined},addEvent:function($,A,_){if(!this["_"+$]||!this["_"+$].add){this["_"+$]=new sfs.delegate();tfn=(function(_){_.cancelBubble=!!this.cb;this["_"+$].execute(_,this)}).bindAsEventListener(this);if(this.addEventListener)this.addEventListener($,tfn,false);else this.attachEvent("on"+$,tfn)}this["_"+$].add(A,_)},removeEvent:function($,_){if(this["_"+$]&&this["_"+$].remove)this["_"+$].remove(_)}});staticClass("sfs.elements",{elements:function(){},select:function(){var A=Array.toArray(arguments),_=[];for(var $=0;$<this.length;$++)_.concat(this[$].select.apply(this[$],A)||[]);return _},addEvent:function($,A,_){this.execute("addEvent",$,A,_)},removeEvent:function($,_){this.execute("removeEvent",$,_)},cancelBubble:function($){this.execute("cancelBubble",$)},Class:function($){this.execute("Class",$)},Style:function($){this.execute("Style",$)},toggle:function(){this.execute("toggle")},hide:function(){this.execute("hide")},show:function(){this.execute("show")},removeTo:Array.prototype.remove,remove:method(function(){this.execute("remove")},function($){this[$].remove();this.removeTo($)}),removeSibling:function($){this.execute("removeSibling",$)},removeSub:function($){this.execute("removeSub",$)},update:function($){this.execute("update",$)},alpha:function($){this.execute("alpha",$)},background:function($){this.execute("background",$)},ainOnClass:function(A,_,$){this.execute("ainOnClass",A,_,$)},execute:function(){var A=Array.toArray(arguments),_=A.shift();for(var $=0;$<this.length;$++)this[$][_].apply(this[$],A)}});Class("sfs.delegate",{funs:null,delegate:function(){this.funs={}},add:function($,_){if(!sfs.isObjectValues(this.funs,$))this.funs[(_||this.GUID+sfs.random(1000000))]=$},remove:function($){this.funs=sfs.removeObjectValues(this.funs,$)},execute:function(){var _;for(var $ in this.funs)_=this.funs[$].apply(null,Array.toArray(arguments));return _}});Class("sfs.cookie",{cookie:function(){},Get:method("static",function(B){var _=B+"=",A=document.cookie.indexOf(_);if(A==-1)return null;var $=document.cookie.indexOf(";",A+_.length);if($==-1)$=document.cookie.indexOf("&",A+_.length);if($==-1)$=document.cookie.length;var C=unescape(document.cookie.substring(A+_.length,$));if(C.substr(C.length-0)=="#")C=C.substr(0,C.length-1);return C}),Set:method("static",function(E,_,D,C,A,$){var B=E+"="+escape(_)+((D)?"; expires="+D.toGMTString():"")+((C)?"; path="+C:"")+((A)?"; domain="+A:"")+(($)?"; secure":"");if((E+"="+escape(_)).length<=4000)document.cookie=B;else if(confirm("Cookie exceeds 4KB and will be cut!"))document.cookie=B}),remove:method("static",function(A,_,$){if(sfs.cookie.Get(A))sfs.cookie.Set(A,"NULL",new Date(0,1,1),_,$)})});Class("sfs.Timer",{status:false,time:1000,intevalID:null,count:-1,ontick:null,ontickend:null,enabled:true,Timer:function(_,$){this.onTick=new sfs.delegate();this.onTickEnd=new sfs.delegate();this.setTime(_,$);this.start()},setTime:function($,_){this.time=$||this.time;this.count=_||this.count;if(this.status){this.stop();this.start()}},start:function(){this.status=true;this.inteval=setInterval(this.execute.bind(this),this.time)},stop:function(){this.status=false;clearInterval(this.inteval)},execute:function(){if(this.count!=-1){this.count--;if(this.count==0)this.stop()}if(this.enabled){this.onTick.execute();this.onTickEnd.execute()}}});Class("sfs.TimeOuter",{status:false,time:1000,timeOutID:null,count:-1,ontick:null,ontickend:null,enabled:true,TimeOuter:function(_,$){this.onTick=new sfs.delegate();this.onTickEnd=new sfs.delegate();this.setTime(_,$);this.start()},setTime:function($,_){this.time=$||this.time;this.count=_||this.count;if(this.status){this.stop();this.start()}},start:function(){if(this.status==true)return;this.enabled=true;this.status=true;this.timeOutID=window.setTimeout(this.execute.bind(this),this.time)},stop:function(){if(this.status==false)return;this.enabled=false;this.status=false;window.clearTimeout(this.timeOutID)},execute:function(){if(this.count!=-1){if(this.count==0)this.stop();this.count--}if(this.enabled){this.onTick.execute();this.onTickEnd.execute();this.timeOutID=window.setTimeout(this.execute.bind(this),this.time)}}});Class("sfs.monitoring",{monitorings:[],executeMethods:[],onerror:null,onunload:null,time:80000,timeoutID:null,loading:null,monitoring:function(){this.onerror=new sfs.delegate();this.onunload=new sfs.delegate()},start:function(){if(this.loading)this.loading.open(0.5);for(var $=0;$<this.monitorings.length;)if(this.monitorings[$].eval()!=undefined)this.monitorings.remove($);else $++;if(this.monitorings.length!=0){if(this.time>0||this.time==-1)this.timeoutID=this.start.bind(this).delay(0.1);else{this.stop();this.onerror.execute()}if(this.time!=-1){this.time-=100;if(this.time==-1)this.time=0}}else{for(var _=0;_<this.executeMethods.length;_++)this.executeMethods[_]();this.stop();this.onunload.execute()}},stop:function(){clearTimeout(this.timeoutID);if(this.loading)this.loading.close()}});Class("sfs.loading",{panel:null,element:null,status:false,text:"\u6570\u636e\u52a0\u8f7d\u4e2d...",imgUrl:"",doc:"",time:null,closeTime:null,x:10,y:10,loading:function(){},open:function($,B){clearTimeout(this.time);clearTimeout(this.closeTime);if(this.status)return;if($){this.time=this.open.bind(this,null,B).delay($);return}this.status=true;clearTimeout(this.time);clearTimeout(this.closeTime);this.element=(this.panel||sfs.page.root).select("<div style=\"position:absolute;z-index:9998;\"></div>");if(this.doc!="")this.element.update(this.doc);else if(this.imgUrl!="")this.element.select("<img src=\""+this.imgUrl+"\"></img>");else this.element.update("<div style=\"font-size:12px;background-color:#ffff00;padding:2px;padding-left:6px;padding-right:6px;color:#7D5B00;white-space:nowrap;border:1px solid #FFB900;\">"+this.text+"</div>");var C=this.x,_=this.y,A=sfs.page.size();switch(B){case 1:C=A.width-this.element.Width()-C;_=_;break;case 2:C=A.width-this.element.Width()-C;_=A.height-this.element.Height()-_;break;case 3:C=C;_=A.height-this.element.Height()-_;break;case 4:C=A.width/2-this.element.Width()/2;_=A.height/2-this.element.Height()/2;break}this.element.x(C);this.element.y(_)},close:function($){clearTimeout(this.time);clearTimeout(this.closeTime);if(!this.status)return;if($){this.closeTime=this.close.bind(this).delay($);return}if(this.element){this.element.remove();this.element=null}this.status=false;clearTimeout(this.time);clearTimeout(this.time)}});Class("sfs.XMLHttpRequest",{xhr:null,scriptNode:null,scriptNodeTime:null,exeType:"xhr",isStop:false,method:"GET",url:"",type:true,readyState:0,status:null,readystatechange:null,responseText:null,responseStream:null,responseBody:null,responseXML:null,statusText:null,sendParam:null,onreadystatechange:sfs.nullFunction,XMLHttpRequest:function(){this.readystatechange=new sfs.delegate();this.readystatechange.add((function(){this.onreadystatechange()}).bind(this));if(window.ActiveXObject)this.xhr=new window.ActiveXObject("Microsoft.XMLHTTP");else if(window.XMLHttpRequest)this.xhr=new window.XMLHttpRequest();else throw new Error("\u521b\u5efaXMLHttpRequest\u51fa\u9519")},open:function(A,_,$){this.method=A;this.url=sfs.page.toLocation(_);this.type=$;if(sfs.page.getRootLocation(this.url)==sfs.page.rootLocation){this.exeType="xhr";this.xhr.open(this.method,sfs.page.appParameter("exeType","xhr",this.url),this.type)}else{this.exeType="scriptNode";this.abort();this.isStop=true;this.readyState=1}},send:function($){this.sendParam=$;$=($||"").replace(/</g,"%lt;").replace(/>/g,"%gt;");if(this.exeType=="xhr"){this.xhr.onreadystatechange=this.__onreadystatechange.bind(this);this.xhr.send($)}else{var _=sfs.page.appParameter("exeType","scriptNode",this.url);_=sfs.page.appParameter("GUID",this.GUID,_);_=sfs.page.appParameter("parameter",escape($),_);if(_.length>2060)throw new Error("\u8de8\u57df\u8bbf\u95ee,\u53d1\u9001\u7684\u6570\u636e\u8fc7\u957f");this.scriptNodeTime=this.__onreadystatechange.bind(this,4,404).delay(60);this.scriptNode=sfs.page.appScript(_)}},reSend:function(){this.send(this.sendParam)},__onreadystatechange:function($,C,F,E,A,B,_){if(this.exeType=="xhr"){this.readyState=this.xhr.readyState;try{this.status=this.xhr.status}catch(D){}try{this.responseText=this.xhr.responseText}catch(D){}try{this.responseStream=this.xhr.responseStream}catch(D){}try{this.responseBody=this.xhr.responseBody}catch(D){}try{this.responseXML=this.xhr.responseXML}catch(D){}try{this.statusText=this.xhr.statusText}catch(D){}this.readystatechange.execute()}else if(this.isStop){clearTimeout(this.scriptNodeTime);this.readyState=$;this.status=C;this.responseText=F;this.responseStream=E;this.responseBody=A;this.responseXML=B;this.statusText=_;this.readystatechange.execute()}},setRequestHeader:function(_,$){if(this.exeType=="xhr")this.xhr.setRequestHeader(_,$)},getResourceHeader:function($){if(this.exeType=="xhr")return this.xhr.getResourceHeader($)},getAllResourceHeaders:function(){if(this.exeType=="xhr")return this.xhr.getAllResourceHeaders()},abort:function(){if(this.exeType=="xhr")this.xhr.abort();else{this.isStop=false;if(this.scriptNode){this.scriptNode.remove.bind(this.scriptNode).delay(0.001);this.scriptNode=null}clearTimeout(this.scriptNodeTime)}this.readyState=0;this.status=null;this.responseText=null;this.responseStream=null;this.responseBody=null;this.responseXML=null;this.statusText=null}});Class("sfs.request.ajax",{xhrs:null,loading:null,ajax:function(){this.xhrs=[];this.loading=new sfs.loading()},getXhr:function(){for(var $=0;$<this.xhrs.length&&$<5;$++)if(this.xhrs[$].readyState==0)return this.xhrs[$];if(this.xhrs.length<5){var _=this.createXhr();this.xhrs.push(_);return _}else null},createXhr:function(){return new sfs.XMLHttpRequest()},invoke:function(F,G,C,D,B){var _="<Conver><metsod>"+G+"</metsod><Params>";for(var $=0;$<C.length;$++){var A,E;if(sfs.isArray(C[$])){if(C[$].length!=0)A=typeof(C[$][0])+"[]";else A="object[]";E=sfs.toJSON(C[$])}else if(sfs.isObject(C[$])){A="object";if(C[$]=="null")E="null";else E=sfs.toJSON(C[$])}else{A=typeof(C[$]);try{E=C[$].toString()}catch(H){throw new Error(H.message+"\n\n"+G+"\n\n"+C)}}_+="<Param Type=\""+A+"\">"+E+"</Param>"}_+="</Params></Conver>";this.send(F,_,D,B,"invoke")},send:function(D,B,C,A,_){if(A)A.open(0.4);var $=this.getXhr();if(!$){this.send.bind(this,D,B,C,A,_).delay(0.2);return}C=C||sfs.nullFunction;$.onreadystatechange=this.onreadystatechange.bind(this,$,C,A,_);$.open("POST",(D=="#"?sfs.page.href():D)+"?date="+new Date().getTime(),true);$.setRequestHeader("Content-Type","application/x-www-form-urlencoded;");$.send(B)},onreadystatechange:function(xhr,onload,loading,type){if(xhr.readyState!=4)return;if(xhr.status==200){var text=xhr.responseText;if(type=="invoke"){var n=select(text),ns=n.subs(),p={Status:null,Value:null,Type:null,IsObject:null,Error:null,DateTime:null};p.Status=eval(ns[0].cons());p.IsObject=ns[1].getAttribute("IsObject")=="True"?true:false;p.Type=ns[1].getAttribute("Type");if(p.IsObject)p.Value=ns[1].cons().evalJSON();else p.Value=ns[1].cons();p.Error=ns[2].cons();p.DateTime=eval(ns[3].cons());if(p.Status==1)throw new Error(p.Error);else onload(p)}else onload(text)}else{if(loading)loading.close();xhrStatus=xhr.status;xhr.abort();if(xhrStatus==404)throw new Error("\u8bf7\u6c42URL\u5730\u5740\u9519\u8bef");else if(xhrStatus==500)throw new Error("\u5e94\u7528\u7a0b\u5e8f\u4e2d\u670d\u52a1\u5668\u53d1\u751f\u9519\u8bef");else throw new Error((xhrStatus||"\u672a\u6307\u5b9a\u7684")+"\u9519\u8bef")}if(loading)loading.close();xhr.abort()}});sfs.ajax=new sfs.request.ajax();staticClass("sfs.page",{html:select("html"),head:select("head"),title:select("title"),mouseStatus:{buttonKey:-1,x:0,y:0,x_:0,y_:0},rootLocation:"",location:document.location.href.replace(/\?.*$/,"").replace(/\/[^\/]*$/,"")+"/",element:document.documentElement,scriptLocation:"",scriptLibs:[],isLoadEnd:false,isInitOver:false,preparedLibs:{"qcyx.bubble.js":"http://img1.17ZO.com/js/Qcyx.bubble.js","qcyx.control.js":"http://img2.17ZO.com/js/Qcyx.Control.js","qcyx.dropdownlist.js":"http://img3.17ZO.com/js/Qcyx.dropDown.js","qcyx.dropdown.js":"http://img3.17ZO.com/js/Qcyx.dropDown.js","qcyx.event.js":"http://img4.17ZO.com/js/Qcyx.Event.js","qcyx.utils.js":"http://img4.17ZO.com/js/Qcyx.Utils.js","qcyx.forms.js":"http://img1.17ZO.com/js/Qcyx.forms.js","qcyx.infomation.js":"http://img2.17ZO.com/js/Qcyx.infomation.js","qcyx.mark.js":"http://img3.17ZO.com/js/Qcyx.Mark.js","qcyx.ui.image.js":"http://img4.17ZO.com/js/Qcyx.UI.Image.js","qcyx.ui.textarea.js":"http://img1.17ZO.com/js/Qcyx.UI.Textarea.js","qcyx.validatorupdatedisplay.js":"http://img2.17ZO.com/js/Qcyx.validatorUpdateDisplay.js","qcyx.city.js":"http://img2.17ZO.com/js/qcyx.city.js","qcyx.webim.js":"http://img1.17ZO.com/js/qcyx.webim.js","sfs.ani.js":"http://img3.17ZO.com/js/SFS.Ani.js","sfs.data.js":"http://img4.17ZO.com/js/SFS.Data.js","sfs.js":"http://img1.17ZO.com/js/SFS.js","sfs.ui.button.js":"http://img2.17ZO.com/js/SFS.UI.Button.js","sfs.ui.forms.js":"http://img3.17ZO.com/js/SFS.UI.Forms.js","sfs.ui.js":"http://img4.17ZO.com/js/SFS.UI.js"},libs:{},page:function(){this.rootLocation=this.getRootLocation(document.location.href);this.scriptLocation=this.getScriptLocation("sfs.js");window.onload=this.pageLoad.bindAsEventListener(this);window.onunload=this.onunload.execute.bindAsEventListener(this.onunload);window.onresize=this.onresize.execute.bindAsEventListener(this.onresize);window.onscroll=this.onscroll.execute.bindAsEventListener(this.onscroll);window.onfocus=this.onfocus.execute.bindAsEventListener(this.onfocus);window.onblur=this.onblur.execute.bindAsEventListener(this.onblur);this.element.onclick=this.onclick.execute.bindAsEventListener(this.onclick);this.element.oncontextmenu=this.oncontextmenu.execute.bindAsEventListener(this.oncontextmenu);this.element.onmousemove=this.onmousemove.execute.bindAsEventListener(this.onmousemove);this.element.onmouseover=this.onmouseover.execute.bindAsEventListener(this.onmouseover);this.element.onmousedown=this.onmousedown.execute.bindAsEventListener(this.onmousedown);this.element.onmouseout=this.onmouseout.execute.bindAsEventListener(this.onmouseout);this.element.onmouseup=this.onmouseup.execute.bindAsEventListener(this.onmouseup);this.onmousedown.add(this.onpagemousedown.bind(this));this.onmouseup.add(this.onpagemousedown.bind(this));this.onmousemove.add(this.onpagemousemover.bind(this));document.write("<span id=\"sfs_root_\" style=\"position:absolute;left:0px;top:0px;z-index:9999;overflow:inherit;\"><span style=\"display: none;\">SFS</span>"+"<div id=\"sfs_CoverLayer_\" style=\"position:absolute;left:0px;top:0px;z-index:9999;display:none;background-color:#FFFFFF;\"></div></span>");this.root=select("#sfs_root_");this.coverLayer=select("#sfs_CoverLayer_");this.coverLayer.alpha(1);var A=document.body;for(var _ in sfs.element){try{if(_!="background")A[_]=sfs.element[_]}catch(B){}}this.body=A;this._status={length:this.body.innerHTML.length,count:0};if(sfs.browser.IE){document.write("<script id=\"__ie_onload_sc\" defer=\"true\" src=javascript:void(0)><"+"/script>");var $=select("#__ie_onload_sc");$.addEvent("readystatechange",(function(){if($.readyState=="complete")this.pageDOMInit()}).bind(this),"statusChange")}else if(document.addEventListener)document.addEventListener("DOMContentLoaded",this.pageDOMInit.bind(this),false);else this.onload.add(this.pageDOMInit)},pageDOMInit:function(){if(this.scriptLibs.length!=0)for(i=0,len=this.scriptLibs.length;i<len;i++)if(this.scriptLibs[i].status!="loadend"){this.pageDOMInit.bind(this).delay(0.1);return}this.control.createControl();this.oninit.execute();this.isInitOver=true},pageLoad:function(){if(!this.isInitOver){this.pageLoad.bind(this).delay(0.1);return}this.onload.execute();this.isLoadEnd=true;this.onloaded.execute()},toLocation:function(A){switch(A.substr(0,1)){case"/":A=this.rootLocation+A.substr(1);break;case".":A=this.location+A;break;default:if(A.substr(0,7)!="http://")A=this.location+A}while(A.match(/\.{2,}\//)){var $=A.replace(/\.{2,}\/.*$/,""),_=A.match(/\.{2,}\/.*$/)[0].replace(/^\.{2,}\//,"");if($.length>this.rootLocation.length)$=$.replace(/[^\/]+\/$/,"");A=$+_}return A},getRootLocation:function($){return this.toLocation($).match(/http:\/\/[^\/]*/)+"/"},getScriptLocation:function(_){_=_.toLowerCase();var A=document.getElementsByTagName("script");for(var $=0;A[$].src&&$<A.length;$++){var B=A[$].src.toLowerCase().replace(/\?.*$/,"");if(B.match(/[^\/]+$/)[0]==_)return this.toLocation(B).replace(/[^\/]+$/,"")}},appStyle:method(function(_,A){for(var C=0;C<_.length;C++){var B=select("link"),D=this.toLocation(_[C]),E=true;B=sfs.isElement(B)?[B]:(B||[]);for(var $=0;$<B.length;$++)if(B[$].href&&this.toLocation(B[$].href)==D){if(A)B[$].remove();else E=false;$=B.length}if(E)this.appStyle(D)}},function(_){var $=select(document.createElement("link"));$.type="text/css";$.rel="stylesheet";$.href=this.toLocation(_);this.head.addSub($);return $}),appScript:method(function(_,G,C,B){for(var E=0;E<_.length;E++){var D=select("script"),F=this.toLocation(_[E]),H=true;D=sfs.isElement(D)?[D]:(D||[]);for(var $=0;$<D.length;$++)if(D[$].src&&this.toLocation(D[$].src)==F){if(B)D[$].remove();else H=false;$=D.length}if(H)this.appScript(F)}var A=new sfs.monitoring();A.monitorings=G;A.executeMethods=C;A.loading=new sfs.loading();A.onerror.add(function(){throw new Error("\u4e0b\u8f7dJavaScript\u6587\u4ef6\u51fa\u9519!")});A.start()},function(_){var $=select(document.createElement("script"));this.head.addSub($);$.type="text/javascript";$.src=this.toLocation(_);return $}),addScript:function($){$=$.toLowerCase();if(this.preparedLibs[$]!=null)$=this.preparedLibs[$];if(this.libs[$]!=null)return;this.libs[$]=true;sObj=select(document.createElement("script"));if(sfs.browser.IE)sObj.addEvent("readystatechange",this.scriptReadyStatusChange.bind(this,sObj),"statusChange");else sObj.addEvent("load",this.scriptLoad.bind(this,sObj),"statusChange");sObj.src=$;sfs.page.head.addSub(sObj);this.scriptLibs.push({src:$,status:"loading",scriptObj:sObj})},scriptReadyStatusChange:function($){if($.readyState=="complete"||$.readyState=="loaded")this.scriptLoad($)},scriptLoad:function($){this.scriptLibs.each(function(_){if(_.scriptObj.src==$.src)_.status="loadend"})},frame:function($){return select($).contentWindow},href:function($){var _=/\?|#.*$/gm;return($||document.location.href).replace(_,"")},parameter:function(B,_){var A=new RegExp("(\\?|#|&)"+B+"=([^&#]*)(&|#|$)"),$=(_||document.location.href).match(A);return $?unescape($):null},appParameter:function(A,$,_){_=_?_:document.location.href;_+=(_.match(/\?/)?"&":"?")+A+"="+$;return _},size:method(function(A,B){if(window.parent==window.self)resizeTo(A,B);else{this.size(A,B,window.self);var D=_.parent.window.document.getElementsByTagName("iframe"),_=_.parent.window.document.getElementsByTagName("frame"),C=([]).concat(D||[]).concat(_||[]);for(var $=0;$<C.length;$++)if(C[$].contentWindow==window.self){C[$].style.width=A+"px";C[$].style.height=B+"px"}}},function(){return{width:this.element.clientWidth!=0?this.element.clientWidth:this.element.offsetWidth,height:this.element.clientHeight!=0?this.element.clientHeight:this.element.offsetHeight}}),onpagemousedown:function($){if(sfs.browser.IE)switch($.button){case(1):this.mouseStatus.buttonKey=0;break;case(4):this.mouseStatus.buttonKey=1;break;case(2):this.mouseStatus.buttonKey=2;break;case(3):this.mouseStatus.buttonKey=3;break;case(5):this.mouseStatus.buttonKey=4;break;case(6):this.mouseStatus.buttonKey=5;break;case(7):this.mouseStatus.buttonKey=6;break}else this.mouseStatus.buttonKey=$.button;if($.type=="mouseup")this.mouseStatus.buttonKey=-1},onpagemousemover:function($){this.mouseStatus.x=$.clientX;this.mouseStatus.y=$.clientY;this.mouseStatus.x_=this.mouseStatus.x+this.element.scrollLeft;this.mouseStatus.y_=this.mouseStatus.y+this.element.scrollTop},openCoverLayer:function(){this.coverLayer.show();this.setCoverLayerSize();this.setCoverLayerXY();this.onscroll.add(this.setCoverLayerXY.bind(this),"onCoverLayerXY");this.onresize.add(this.setCoverLayerSize.bind(this),"onCoverLayerSize")},setCoverLayerSize:function(){var $=this.size();this.coverLayer.Width($.width);this.coverLayer.Height($.height)},setCoverLayerXY:function(){this.coverLayer.x(this.element.scrollLeft);this.coverLayer.y(this.element.scrollTop)},closeCoverLayer:function(){this.coverLayer.hide();this.onscroll.remove("onCoverLayerXY");this.onresize.remove("onCoverLayerSize")},onmousemove:new sfs.delegate(),onmousedown:new sfs.delegate(),onmouseup:new sfs.delegate(),oncontextmenu:new sfs.delegate(),onclick:new sfs.delegate(),onunload:new sfs.delegate(),oninit:new sfs.delegate(),onload:new sfs.delegate(),onfocus:new sfs.delegate(),onblur:new sfs.delegate(),onloaded:new sfs.delegate(),onresize:new sfs.delegate(),onscroll:new sfs.delegate(),onmouseover:new sfs.delegate(),onmouseout:new sfs.delegate()});Class("sfs.page.control",{element:null,onload:null,control:function(){this.onload=new sfs.delegate()},createControl:method("static",function(){var B=([]).concat(select("span")||[]).concat(select("div")||[]).concat(select("ul")||[]).concat(select("li")||[]).concat(select("dd")||[]).concat(select("a")||[]).concat(select("input")||[]).concat(select("em")||[]).concat(select("textarea")||[]);for(var $=0;$<B.length;$++){var A=B[$].getAttribute("type"),C=B[$].id,_=B[$].getAttribute("sfstype");if(_&&_.toLowerCase().indexOf("sfs:")==0)A=_;if(B[$].parentNode){isAttribute=!!B[$].parentNode.getAttribute("attribute");if(A!=null&&A.substr(0,3).toLowerCase()=="sfs"&&!isAttribute){if(C==null||C=="")throw new Error("\u521b\u5efa\u63a7\u4ef6\u65f6\u7f3a\u5c11ID\u503c");try{window[C]=D(B[$])}catch(E){}}}}function D(J){var I=J.getAttribute("init"),G=J.getAttribute("sfsinit");if(G&&G.trim().length>0)I=G;I=I?I.eval():[];I=sfs.isArray(I)?I:[I];A=J.getAttribute("type"),_=J.getAttribute("sfstype");if(_&&_.toLowerCase().indexOf("sfs:")==0)A=_;var F=A.substr(4).eval(),E=new F(I[0],I[1],I[2],I[3],I[4],I[5],I[6],I[7],I[8],I[9],I[10],I[11],I[12],I[13],I[14],I[15],I[16],I[17],I[18],I[19]),H=J.subs();for(var $=0;$<H.length;$++){var C=H[$].getAttribute("attribute");if(C){var K=H[$].getAttribute("name"),B=H[$].cons();if(C=="object"){if(B.isHTML())E[K]=D(H[$].sub(0));else E[K]=B.eval()}else if(C=="event")E[K].add(B.eval());else E[K]=(C+" "+B).eval()}}E.element=J;E.onload.execute();return E}})});
try{ if(window.parent.location){ 
var hostName = window.location.hostname.toLowerCase();
if( hostName.indexOf( '17zo.com') == -1  && hostName != 'localhost')  {}
else{
var reg=/\/people|\/members/i;if(window.location.href==window.parent.location.href&&!reg.test(window.location.pathname))sfs.page.addScript("qcyx.webim.js")}}}catch(e){}