/* ------- created by hirayama ------- */
function openWebChart4D() {
	
	var Digitnumber = 4;
	var _strStockCode = null;
	
	/* ----------------------------------- */
	_txt = document.brandCoderetrieval.brandCode.value;
	_result = '';
	for (i=0; i<_txt.length; i++) {
		_result = _txt;
		if (i==(Digitnumber-1)) {
			_strStockCode = eval(_result);
			//alert(_strStockCode);
			
			
			/* ----------------------------------- */
			var _url='./';
			var _name='popupWin';
			
			var popupWin = window.open(_url, _name, 'toolbar=no,location=no,menubar=no,resizable=no,scrollbars=no,width=1020,height=718');
			popupWin.document.open("text/html; charset=utf-8");
			popupWin.focus();
			//popupWin.document.write(_strStockCode);
			
			
			var _fname='goAction';
			var _action='http://www.bsta.jp/masuda_chart_js/homechart4Dss.php';
			var _target='popupWin';
			
			popupWin.document.write('<form name="',_fname,'" action="',_action,'" method="post" target="',_target,'">');
			popupWin.document.write('<input type="hidden" name="request" value="',_strStockCode,'" />');
			popupWin.document.write('</form>');
			
			
			if(navigator){
				if(navigator.userAgent){
					if(navigator.userAgent.indexOf("Gecko/") != -1){
						popupWin.document.write('document.getElementsByTagName(_fname)[0].name');
					}
				}
			}
			
			popupWin.document.getElementsByName(_fname)[0].submit();	
			/* ----------------------------------- */
			
			
			/* fujisima add */
			document.brandCoderetrieval.brandCode.value = '';
			
		}
	}
	/* ----------------------------------- */
	
}
