PDA

View Full Version : Php Help



JaanEST
07-08-2006, 05:40 AM
Okay...

i have this HTML form:


<html>
<body>
<center>
<FORM name="Join *BB* Form" method="POST" action="send.php">
<INPUT type="text" style="position:absolute;left:107px;top:6px;width:168px;z-index:39" size="21"

name="NAME" value="">
<INPUT type="text" style="position:absolute;left:107px;top:35px;width:168px; z-index:40" size="21"

name="ET" value="">
<DIV style="position:absolute;left:19px;top:6px;width:45px;hei ght:16px;z-index:41" align="left">
<FONT style="font-size:13px" color="#000000" face="Arial">Name:</FONT>
</DIV>
<DIV style="position:absolute;left:19px;top:37px;width:77px;he ight:16px;z-index:42" align="left">
<FONT style="font-size:13px" color="#000000" face="Arial">Name in ET:</FONT>
</DIV>
<INPUT type="text" style="position:absolute;left:109px;top:67px;width:168px; z-index:43" size="21"

name="AGE" value="">
<DIV style="position:absolute;left:20px;top:68px;width:33px;he ight:16px;z-index:44" align="left">
<FONT style="font-size:13px" color="#000000" face="Arial">Age:</FONT>
</DIV>
<DIV style="position:absolute;left:19px;top:129px;width:59px;h eight:16px;z-index:45"

align="left">
<FONT style="font-size:13px" color="#000000" face="Arial">OId clan:</FONT>
</DIV>
<INPUT type="text" style="position:absolute;left:109px;top:128px;width:168px ;z-index:46"

size="21" name="OLDCLAN" value="">
<TEXTAREA name="WHYLEFT"

style="position:absolute;left:107px;top:158px;width:174px ;height:69px;z-index:47" rows=4

cols=19></TEXTAREA>
<DIV style="position:absolute;left:18px;top:184px;width:83px;h eight:16px;z-index:48"

align="left">
<FONT style="font-size:13px" color="#000000" face="Arial">Why you left:</FONT>
</DIV>
<TEXTAREA name="WHYJOIN"

style="position:absolute;left:108px;top:241px;width:174px ;height:69px;z-index:49" rows=4

cols=19></TEXTAREA>
<DIV style="position:absolute;left:20px;top:262px;width:96px;h eight:32px;z-index:50"

align="left">
<FONT style="font-size:13px" color="#000000" face="Arial">Why you want to join *BB*:</FONT>
</DIV>
<INPUT type="submit" name="" value="Send"

style="position:absolute;left:206px;top:330px;width:75px; height:24px;z-index:51">

</FORM>



</center>
</body>
</html>
and if i press send it goes to here:


<?
$mailbody = "$name $ETName $Age $OldClan $Whyleft $WhyWantJoin $mailsubj
$name $POST[NAME]
$ETName $POST[ET]
$Age $POST[AGE]
$OldClan $POST[OLDCLAN]
$Whyleft $POST[WHYLEFT]
$WhyWantJoin $POST[WHYJOIN]
$mailsubj New Player Who Wants Join *BB*";
echo $mailbody;
?>
Everything should work but i don't know why...it don't show nothing only blank page...

It have to show names and thingys... but it's wierd

Andy128
07-08-2006, 05:44 AM
What is it that you are trying to do? Mail this info to your e-mail? Simply
display in a browser?

Andy

JaanEST
07-08-2006, 05:47 AM
it will just display those things what this guy have written there... (to this form)

Andy128
07-08-2006, 06:01 AM
The form needs to do something. Do you want it sent to you in an e-mail? Simply displayed on the monitor? Or put into a data base.

How do you want it to show? In what format.

Andy

JaanEST
07-08-2006, 05:33 PM
hm... it have to display only this text... like a confirm page...it have to display only this text... nothing else

navaldesign
07-08-2006, 09:17 PM
You need to set the encoding type to multipart / form data"

JaanEST
07-09-2006, 05:43 PM
well i tryed it like this:


<?php
$name = $_POST['NAME'];
$ETName = $_POST['ET'];
$Age = $_POST['AGE'];
$OldClan = $_POST['OLDCLAN'];
$Whyleft = $_POST['WHYLEFT'];
$WhyWantJoin = $_POST['WHYJOIN'];
$mailsubj = "New Player Who Wants Join *BB*";

$mailbody = array($name, $ETName, $Age, $OldClan, $Whyleft, $WhyWantJoin, $mailsubj);

foreach($mailbody as $mailbody){
echo $mailbody.'<br />';
}
?>

and it worked...