    /***************************************************************************

        JavaScript 関数ライブラリー

    ***************************************************************************/

		//  吉田追加　2005.04.26　ウィンドウをサイズと場所、スクロールバーの有無、リサイズの可否を指定してオープン
		function wOpen(page, wname, w, h, l, t, s, r){
			newWin = window.open(page, wname, "width="+w+" ,height="+h+", top="+t+" ,left="+l+", scrollbars="+s+", resizable="+r);
		}
		
    // テストデレクトリーか、本番デレクトリーかを判断して、URLを返す。
    //--------------------------------------------------------------------------
    function getURLstring( str ){
        if( location.hostname == 'www.dig.co.jp' ){
            str = '/hibiyakadan/company' + str;
        }else if( location.hostname == 'www.hibiya.co.jp' ){
            var strPath = location.pathname;
            if( strPath.indexOf( '/crunky/' ) != -1 ){
                str = '/crunky' + str;
            }
        }
    return str;
    }

    // セミナーページを開く
    //--------------------------------------------------------------------------
    function openSeminerFlash(){
        var str_url = getURLstring( '/news/seminar/flash/' );
        var __win   = window.open(str_url,'','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes' );
            __win.focus();
    }

    //
    //--------------------------------------------------------------------------
    function openDesignersView2_test(){
        var __win = window.open('http://www.hibiya.co.jp/crunky/designers/','DesignersView2_test','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes' );
            __win.focus();
    }

    //
    //--------------------------------------------------------------------------
    function openDesignersView2(){
        var __win = window.open('http://www.hibiya.co.jp/petale/','DesignersView2','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes' );
            __win.focus();
    }

    // デザイナーズ viewを返す。
    //--------------------------------------------------------------------------
    function openDesignersView(){
        var str_url = getURLstring( 'http://www.hibiya.co.jp/petale/' );
        var __win = window.open(str_url,'DesignersView','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes' );
            __win.focus();
    }


    // デザイナーズ viewを返す。
    //--------------------------------------------------------------------------
    function sendURLtoParent( str_url ){
        str_url = getURLstring( str_url );

        if( window.opener.closed ){
            window.location.href = str_url;
            return;
        }
        window.opener.location.href = str_url;
        window.opener.focus();
    }

    // 日比谷が開かれていなければ、日比谷を開く
    //--------------------------------------------------------------------------
    function isOpener(){
        if( window.opener == null ){
            location.href = getURLstring( '/' );
        }
    }