﻿// JavaScript Document
function URLencode(sStr) 
{
    return escape(sStr).
             replace(/\+/g, '%2B').
                replace(/\"/g,'%22').
                   replace(/\'/g, '%27').
                     replace(/\//g,'%2F');
}



/* 

这是把事件动作绑定到菜单上的函数
*/
function attachXMenu(objid){
	var tds=objid.getElementsByTagName('li');
	for(var i=0;i<tds.length;i++){
		with(tds[i]){
			onmouseover=function(){
				with(this){
					style.background='#f1f1f1'; //这是鼠标移上去时的背景颜色

				}
			}
			onmouseout=function(){
				with(this){
                    style.background='url(/images/xu.jpg) repeat-x bottom';
				}
			}
		}
	}
}



(function () {
var ie = !!(window.attachEvent && !window.opera);
var wk = /webkit\/(\d+)/i.test(navigator.userAgent) && (RegExp.$1 < 525);
var fn = [];
var run = function () { for (var i = 0; i < fn.length; i++) fn[i](); };
var d = document;
d.ready = function (f) {
if (!ie && !wk && d.addEventListener)
return d.addEventListener('DOMContentLoaded', f, false);
if (fn.push(f) > 1) return;
if (ie)
(function () {
try { d.documentElement.doScroll('left'); run(); }
catch (err) { setTimeout(arguments.callee, 0); }
})();
else if (wk)
var t = setInterval(function () {
if (/^(loaded|complete)$/.test(d.readyState))
clearInterval(t), run();
}, 0);
};
})();
//document.ready(function(){
//document.getElementById('mendcity').focus(); //找到
//});
//alert(document.getElementById('test')); //null 没找到




function open1_w()
{
	var diag = new Dialog();
    diag.Title = "选择抵达目的地列表";
	diag.URL = "intcitylist.asp";
	diag.Width = 650;
	diag.Height = 500;
//	diag.Modal = false;
//    diag.Drag=false;
	diag.show();
}
