¾Ë·ÁÁֽŵ¥·Î ¼öÁ¤Çߴµ¥¿ä.
Á¦·Î º¸µå ¼³Ä¡ÇÑ ÆäÀÌÁö¿¡¼µµ ¸ÞÀÏÀº Àß ¿À°í Àִµ¥ ^^
1.sub.php¿¡¼ ³»¿ë ÀÔ·ÂÀ» ÇÏÁö ¾Ê°í ½ÅûÇϱâ¹öÆ° ´·¯µµ alertâ ¾È¶ß°í ¸ÞÀÏÀü¼ÛÀÌ ±×³É µÇ±¸¿ä.
2.email_send.php ·Î ³Ñ¾î°¡¼ ´Ù½Ã sub.php·Î ³Ñ¾î¿ÀÁö ¾Ê°í ÀÖ½À´Ï´Ù.
Á¦°¡ ¾Ë·ÁÁֽŵ¥·Î Àß ¼öÁ¤Çß´ÂÁö ¸ð¸£°Ú³×¿ä.
sub.php --------------------------------------------------
<script>
function email_sendit(frm)
{
if ( frm.email_name1.value == "" )
{
alert('¼º¸íÀ» ÀÔ·ÂÇØÁÖ¼¼¿ä.');
frm.email_name1.focus();
return false;
}
if ( frm.email_tel.value == "" )
{
alert('¿¬¶ôó¸¦ ÀÔ·ÂÇØÁÖ¼¼¿ä.');
frm.email_tel.focus();
return false;
}
if ( frm.email_memo.value == "" )
{
alert('¹®Àdz»¿ëÀ» ÀÔ·ÂÇØÁÖ¼¼¿ä.');
frm.email_memo.focus();
return false;
}
else
{
frm.emailReturnUrl = window.location.href;
return true;
}
if ( $_POST["emailSendChk"] == "ok" )
{
alert('Àü¼ÛÀÌ ¿Ï·áµÇ¾ú½À´Ï´Ù.');
}
else
{
<table width="166" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="../img/online_01.gif" width="166" height="51"></td>
</tr>
<tr>
<td align="center" background="../img/online_bg.gif"> <table width="130" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="17%" height="20"><img src="../img/online_03.gif" width="44" height="12"></td>
<td>
<?=$email_name1?>
</td>
</tr>
<tr>
<td height="20"><img src="../img/online_04.gif" width="44" height="12"></td>
<td>
<?=$email_tel?>
</td>
</tr>
<tr>
<td height="20"><img src="../img/online_05.gif" width="44" height="12"></td>
<td> </td>
</tr>
<tr>
<td colspan="2">
<?=$email_memo?>
</td>
</tr>
<tr align="center">
<td height="70" colspan="2"><img src="../img/online_06.gif" width="122" height="55"></td>
</tr>
</table></td>
</tr>
<tr>
<td><img src="../img/online_02.gif" width="166" height="8"></td>
</tr>
</table>
}
}
</script>
<form action="/include/email_send.php" method="post" onSubmit="return email_sendit(this)">
<input type="hidden" name="emailReturnUrl" value="">
//ÀÔ·ÂÆû
<input type="image" name="image" onFocus="this.blur()" onClick="email_sendit(this.form)" src="../img/online_btn.gif" width="55" height="16">//À̹ÌÁö·Î ³Ö°í ½Í¾î¼ ÀÌ·¸°Ô ÇغýÀ´Ï´Ù.
email_send.php ----------------------------------------------
´Ù¸¥ ű״ ´Ù Áö¿ì°í ¾Æ·¡¼Ò½º ³Ö¾ú½À´Ï´Ù.
<?
¸ÞÀϺ¸³»´Â ¼Ò½º
echo "
<form action='$_POST[emailReturnUrl]' method='post'>
<input type='hidden' name='emailSendChk' value='ok'>
</form>
<script>
document.fomrs[0].submit();
</script>
";
?>
===================== ÀÌ»óÀ̱¸¿ä.
sub.php ÀÎŬ·çµå µÇ´Â °÷¿¡ <?php include"include/sub.php"; ?>ÀÌ·¸°Ô ³Ö¾ú½À´Ï´Ù.
¾îµð¼ À߸ø Àû¿ë½ÃŲ°Ç°¡¿ä?? ´Ù½ÃÇѹø ºÎŹµå¸³´Ï´Ù.
¾Æ, Å×½ºÆ®ÆäÀÌÁö´Â
http://www.surysury.com/index.html
http://www.surysury.com/bbs/zboard.php?id=shop
ÀÔ´Ï´Ù.