The Daily Static
  The Daily Static
UF Archives
Register
UF Membership
Ad Free Site
Postcards
Community

Geekfinder
UFie Gear
Advertise on UF

Forum Rules
& FAQ


Username

Password


Create a New Account

 
 

Back to UserFriendly Strip Comments Index

PHP4 Problem: too many variables? by wwill 2004-12-06 10:53:40
It's a simple mailable input form. So why does:

<body>
$name = $_REQUEST['name'];
$depart = $_REQUEST['depart'];
$domain = $_REQUEST['domain'];
$phone = $_REQUEST['phone'];
$email = $_REQUEST['email'];
$area = $_REQUEST['area'];
$notes = $_REQUEST['notes'];
$str = $name. " , " .$email. " , " .$depart. " , ". $phone. " , " .$email. " , " .$area. " , " .$notes;
mail( "XXXYYYY@xyz.edu", "Webmaster Listing", "$str");
?>
[p]Thank you
</body>

work, when this doesn't:

<body>
$name = $_REQUEST['name'];
$depart = $_REQUEST['depart'];
$domain = $_REQUEST['domain'];
$phone = $_REQUEST['phone'];
$email = $_REQUEST['email'];
$area = $_REQUEST['area'];
$notes = $_REQUEST['notes'];
mail( "XXXXYYYY@xyz.edu", "Webmaster Listing", "$name", "$depart", "$domain", "$phone", "$email", "$area", "$notes");
?>
[p]Thank you
</body>

The mail statement will work if the number of variables after "Webmaster Listing" is kept to only one or two, but fails if greater than two; silently, no html output, no email generated (the "Thank You" string, and the switch on this line to square brackets vice the lt/gt pair is due to the html limitations of this forum, not the original working code).

Did the server admin compile in or php.ini some limit on the number of variables in a mail statement? Anyone ever had a similar PHP4 problem?

--
wwill
[ Reply ]
  I thought the mail function only took three parms (n/t) by IronPIP2004-12-06 10:58:55
  Here's why... by Scirocco2006-11-19 12:55:59
    Thanks. Did it. should read the man page. (n/t) by wwill2004-12-06 13:31:58
  you need a <? in there, too (n/t) by Nessalc2004-12-06 11:18:25

 

[Todays Cartoon Discussion] [News Index]

Come get yer ARS (Account Registration System) Source Code here!
All images, characters, content and text are copyrighted and trademarks of J.D. Frazer except where other ownership applies. Don't do bad things, we have lawyers.
UserFriendly.Org and its operators are not liable for comments or content posted by its visitors, and will cheerfully assist the lawful authorities in hunting down script-kiddies, spammers and other net scum. And if you're really bad, we'll call your mom. (We're not kidding, we've done it before.)