		function init() {
			try {
				var d = document.getElementById("url");
				d.focus();
				d.select();
			} catch(e) {
				try {
					var d = document.getElementById("makeurl");
					d.focus();
					d.select();	
				} catch(e) {
					try {
						var d = document.getElementById("aiword");
						d.focus();
					} catch (e) {
					}
				}
			}
			
			try {
				var d = document.getElementById("nazocolor");
				var color = Math.floor(Math.random() * 0xFFFFFF).toString(16);
				for(count = color.length; count < 6; count++){
					color = "0" + color;
		     	}
		     	color = "#" + color;
				d.style.color = color;
			} catch (e) {
			}
		}

		function disp_opt() {
			var d = document.getElementById("option");
			var o = document.getElementById("optiontab");
			if (d.style.display == "none" || d.style.display == "") {
				d.style.display = "block";
				o.innerHTML = "-オプションを非表示";
			} else {
				d.style.display = "none";
				o.innerHTML = "+オプションを表示";
			}
			return false;
		}


function copy2clip_getData(param) {
	var d = document.getElementById("clipstatus");
	d.innerHTML = "コピーされました";
	var text = document.getElementById("makeurl").value;
	if(window.navigator.userAgent.toLowerCase().indexOf("msie") > -1) {
		window.clipboardData.setData('text', text);
		return null;
	} else {
		return text;
	}
}
