$(function() { if (isfrontenv()) { var _wd = new wd().init(); } else { $("body").addclass("loaded"); var _wd = new wd(); _wd.subtycate(); _wd.subnewscate(); _wd.subproductscate(); } }); function wd() {}; wd.prototype.init = function() { this._b = $("body"); this.body = this._b; this.nav(); if (this._b.attr("id") == "index") { this.index(); } else { this.sub(); } return this; } wd.prototype.common = function() { var _ = this; } wd.prototype.timer = function(s, fn) { var _ = this; var i = 0; var w = setinterval(function() { i++; if (i > 500) { clearinterval(w); } var d = $(s); if (d.length) { clearinterval(w); fn && fn(d); } },100); } wd.prototype.nav = function() { var _t = this; } wd.prototype.loading = function() { var _ = this; var w = $("
", { id: "w-loading" }); var close = $("
", { class: "close" }); var container = $("
", { class: "container" }); var iframe = $("