<?/*================================================================================================*//*	SUBJECT			: 학원가맹신청서/*	DATE				: 2003-06-14/*	NAME				: hak9sung/*  TABLE_NAME	: /*  PARMETER		: /*  DISCRIPTION	: 회원관리 페이지 프린트/*/*/*================================================================================================*//*-------------------------------------------------------------------------------------------------*//* 인크루드파일 경로 /*-------------------------------------------------------------------------------------------------*/$DirLoca = "";$HttpDeepCnt = count(explode("/",$PHP_SELF)) - 2;for ($DirNo = 0; $DirNo < $HttpDeepCnt;$DirNo++) { $DirLoca .= "../"; }include $DirLoca."cls/dbcon.conf";include $DirLoca."cls/oci.clas";	/*--------------------------------------------------*//* 오라클 데이테베이스 OPEN/*--------------------------------------------------*/$oci->open();$show = "";$query = "select decode(si_appl,'0','신청서','확인서') appl_txt from ge_si where si_cd = '$cd' ";$oci->parse($query); $oci->exec();while($oci->fetchInto(&$col,$mode=OCI_NUM)){			$show = $show."<ROW APPL_TXT=\"$col[0]\" />\n";}		$oci->parseFree(); $xmlStr = "<PRE>\n";$xmlStr .= "<?xml version=\"1.0\" encoding=\"euc-kr\"  standalone=\"yes\"?>  <DATAPACKET Version=\"2.0\"><METADATA><FIELDS><FIELD attrname=\"APPL_TXT\" fieldtype=\"string\" WIDTH=\"6\"/></FIELDS><PARAMS/></METADATA><ROWDATA>";$xmlStr .= $show;$xmlStr .= "</ROWDATA> </DATAPACKET>\n";$xmlStr .= "DATANAME=_appl_title\n";$show = "";$query = "select a.si_cd, ge_mi_cd_fu(a.mi_cd) mi_nm, a.si_nm, ge_com_cd_fu('g008', a.si_division) division, a.si_addr1||' '||a.si_addr2 addr, a.si_tel, a.si_fax, b.si_pyoung,                         b.si_room_cnt, b.si_curt_cnt, substr(a.reg_strt_day,1,4)||'/'||substr(a.reg_strt_day,5,2)||'/'||substr(a.reg_strt_day,7,2) reg_strt, d.ti_cnt, e.st_cnt, 						b.si_area_sch, b.si_area_st_cnt, ge_com_cd_fu('g007',b.si_location) loca, b.si_org_usr_nm um_nm, c.en_nm, substr(b.si_org_user_jumin,1,6)||'-'||substr(b.si_org_user_jumin,7,7) jumin, 						decode(substr(b.si_org_user_jumin,7,1),'1','남','2','여') sex, b.si_org_user_phone tel, c.cel, c.edu_cls, c.usr_his                 from ge_si a,                             ge_si_etc b,                             (select a.si_cd si_cd, a.um_id um_id, a.et_edu_no edu_no, ge_com_cd_fu('g009',a.si_edu_cls) edu_cls, a.si_usr_his usr_his,  b.um_nm um_nm,                                  b.um_en_nm en_nm, substr(b.um_jumin,1,6)||'-'||substr(b.um_jumin,7,1)||'******'  jumin, decode(substr(b.um_jumin,7,1),'1','남','2','여') sex, 								 b.um_tel tel, b.um_cel cel                               from ge_si_usr a,                                           ge_usr b                               where a.um_id = b.um_id) c,                             (select si_cd, count(si_cd) as ti_cnt from ge_ti group by si_cd) d,                            (select si_cd, count(si_cd) as st_cnt from ge_st group by si_cd) e                 where a.si_cd = b.si_cd(+)                 and a.si_cd = c.si_cd(+)                 and a.si_cd = d.si_cd(+)                 and a.si_cd = e.si_cd(+)                 and a.si_cd = '$cd' ";$oci->parse($query); $oci->exec();while($oci->fetchInto(&$col,$mode=OCI_NUM)){			$show = $show."<ROW SI_CD=\"$col[0]\" MI_NM=\"$col[1]\" SI_NM=\"$col[2]\" DIVISION=\"$col[3]\" ADDR=\"$col[4]\" SI_TEL=\"$col[5]\" SI_FAX=\"$col[6]\" SI_PYOUNG=\"$col[7]\" SI_ROOM_CNT=\"$col[8]\"                                   SI_CURT_CNT=\"$col[9]\" REG_STRT=\"$col[10]\" TI_CNT=\"$col[11]\" ST_CNT=\"$col[12]\" SI_AREA_SCH=\"$col[13]\" SI_AREA_ST_CNT=\"$col[14]\" LOCA=\"$col[15]\"                                   UM_NM=\"$col[16]\" EN_NM=\"$col[17]\" JUMIN=\"$col[18]\" SEX=\"$col[19]\" TEL=\"$col[20]\" CEL=\"$col[21]\" EDU_CLS=\"$col[22]\" USR_HIS=\"$col[23]\" />\n";}		$oci->parseFree(); /*--------------------------------------------------*//* 오라클 데이테베이스 CLOSE/*--------------------------------------------------*/$oci->close();  $xmlStr .= "<?xml version=\"1.0\" encoding=\"euc-kr\"  standalone=\"yes\"?>  					<DATAPACKET Version=\"2.0\"><METADATA><FIELDS>					<FIELD attrname=\"SI_CD\" fieldtype=\"string\" WIDTH=\"12\"/>					<FIELD attrname=\"MI_NM\" fieldtype=\"string\" WIDTH=\"4000\"/>					<FIELD attrname=\"SI_NM\" fieldtype=\"string\" WIDTH=\"30\"/>					<FIELD attrname=\"DIVISION\" fieldtype=\"string\" WIDTH=\"4000\"/>					<FIELD attrname=\"ADDR\" fieldtype=\"string\" WIDTH=\"241\"/>					<FIELD attrname=\"SI_TEL\" fieldtype=\"string\" WIDTH=\"20\"/>					<FIELD attrname=\"SI_FAX\" fieldtype=\"string\" WIDTH=\"20\"/>					<FIELD attrname=\"SI_PYOUNG\" fieldtype=\"fixed\" WIDTH=\"32\"/>					<FIELD attrname=\"SI_ROOM_CNT\" fieldtype=\"fixed\" WIDTH=\"32\"/>					<FIELD attrname=\"SI_CURT_CNT\" fieldtype=\"fixed\" WIDTH=\"32\"/>					<FIELD attrname=\"REG_STRT\" fieldtype=\"string\" SUBTYPE=\"FixedChar\" WIDTH=\"10\"/>					<FIELD attrname=\"TI_CNT\" fieldtype=\"fixed\" WIDTH=\"32\"/>					<FIELD attrname=\"ST_CNT\" fieldtype=\"fixed\" WIDTH=\"32\"/>					<FIELD attrname=\"SI_AREA_SCH\" fieldtype=\"string\" WIDTH=\"100\"/>					<FIELD attrname=\"SI_AREA_ST_CNT\" fieldtype=\"fixed\" WIDTH=\"32\"/>					<FIELD attrname=\"LOCA\" fieldtype=\"string\" WIDTH=\"4000\"/>					<FIELD attrname=\"UM_NM\" fieldtype=\"string\" WIDTH=\"30\"/>					<FIELD attrname=\"EN_NM\" fieldtype=\"string\" WIDTH=\"50\"/>					<FIELD attrname=\"JUMIN\" fieldtype=\"string\" SUBTYPE=\"FixedChar\" WIDTH=\"13\"/>					<FIELD attrname=\"SEX\" fieldtype=\"string\" WIDTH=\"2\"/>					<FIELD attrname=\"TEL\" fieldtype=\"string\" WIDTH=\"20\"/>					<FIELD attrname=\"CEL\" fieldtype=\"string\" WIDTH=\"20\"/>					<FIELD attrname=\"EDU_CLS\" fieldtype=\"string\" WIDTH=\"4000\"/>					<FIELD attrname=\"USR_HIS\" fieldtype=\"string\" WIDTH=\"2000\"/>			</FIELDS><PARAMS/></METADATA><ROWDATA>"; $xmlStr .= $show; $xmlStr .= "</ROWDATA> </DATAPACKET>\n"; $xmlStr .= "DATANAME=_si_info\n"; $xmlStr .= "</PRE>"; echo $xmlStr;?>