<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가 

// 자신만의 코드를 넣어주세요.
$latest_skin_path  =  $g4[path];



?>
<style>
BODY,TABLE,TR,TD {font-size:12px;}
select{behavior: url('./selectbox/selectbox.htc');}
TD{line-height:150%;}
</style>

     <?
     $group_select = "<select id='gr_id' name='gr_id'  style='width:90px;height=:18px;'  setColor='#000000,#FFFFFF,#000000,#E6E4E4,#C0C0C0,#000000'><option value='' align='center'>통합 검색";

     $mct   =  " where  po_poll9  = 'gr_id' "; 
     $mct  .=  " and    po_cnt15  != 1 ";  
     $s_sql = " select po_poll1 as gr_id, po_subject as gr_subject from $g4[site_bill] {$mct} order by po_cnt7, po_subject ";
     $s_result = sql_query($s_sql);

      for ($i=0; $s_row=sql_fetch_array($s_result); $i++)
        $group_select .= "<option value='$s_row[gr_id]'>$s_row[gr_subject]";
        $group_select .= "</select>";
      ?>

     <table border="0" cellspacing="0" cellpadding="0" width="210">
     <form name="fsearchbox" method="get" action="javascript:fsearchbox_submit(document.fsearchbox);">
     <input type="hidden" name="sfl" value="wr_subject">
     <input type="hidden" name="sop" value="and">
     <tr><td height="3"></td></tr>
     <tr>
      <td width="105" align="center"><?=$group_select?><script language="JavaScript">document.getElementById("gr_id").value = "<?=$gr_id?>";</script></td>
      <td align="center"><input name="stx" maxlengt=20 onblur="this.style.background='#ffffff'" style="BORDER-RIGHT: rgb(204,204,204) 1px solid; BORDER-TOP: rgb(204,204,204) 1px solid; BACKGROUND-IMAGE: url(http://seumi.com/scbar/img/sc_bg.gif); BORDER-LEFT: rgb(204,204,204) 1px solid; WIDTH: 190px;height:21px; BORDER-BOTTOM: rgb(204,204,204) 1px solid; "  onfocus="this.style.background='#ffffff'" size="20" maxlength="20"></td>
      <td width="51" align="left"> <input type="image" src="<?=$g4[path]?>/scbar/img/scin.gif" width="47"  border="0"></td>
      </tr></form>
      </table>
      








<script language="JavaScript">
function fsearchbox_submit(f)
{
    if (f.stx.value == '')
    {
        alert("검색어를 입력하세요.");
        f.stx.select();
        f.stx.focus();
        return;
    }

    /*
    // 검색에 많은 부하가 걸리는 경우 이 주석을 제거하세요.
    var cnt = 0;
    for (var i=0; i<f.stx.value.length; i++)
    {
        if (f.stx.value.charAt(i) == ' ')
            cnt++;
    }

    if (cnt > 1)
    {
        alert("빠른 검색을 위하여 검색어에 공백은 한개만 입력할 수 있습니다.");
        f.stx.select();
        f.stx.focus();
        return;
    }
    */

    f.action = "<?=$g4[bbs_path]?>/search.php";
    f.submit();
}
</script>

