FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » PHP Mailto();
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
PHP Mailto(); [message #182041] Sun, 30 June 2013 23:29 Go to previous message
bill is currently offline  bill
Messages: 310
Registered: October 2010
Karma:
Senior Member
Hi,

Win 7, PHP 5.3.5, XAMPP local server, standard Unix remote server:

having a problem with mailto. It's working fine, but ... I can't figure
how to get it to contain all the information I want sent to me. I have
the following:
=========================
$header = "From: abuse(at)hcs-classof64(dot)net";
$to = "abuse(at)hcs-classof64(dot)net";
$subject = "HCS Abuse Form";
$header = "From: $name\r\n";
$header .= "Reply-To: abuse(at)hcs-classof64(dot)net\r\n";
$header .= "Return-Path: abuse(at)hcs-classof64(dot)net\r\n";

mail($to, $subject, $comments , $respond, $header);
========================
And it seems to work fine. But what I'd like to add to the mailto is
the following:
=======================
$browser = $_SERVER['HTTP_USER_AGENT'];
$ipAddress = $_SERVER['REMOTE_ADDR'];
=======================

I've tried the Headers method, simply adding them inlilne. No Good.
I've also tried "and"ing things together like " $comments . $respond "
for instance, but then they all run together and it's difficult to spot
the additional information since there are no line breaks.

For instance, in the mail I receive from the form, Id like to see, each
on their own line with a blank line between is possible:
1. $comments which is the actua verbiage from the visitor,
2, New line,
3. $respond,
4. New line,
4. $ip,
5, New line,
6 $browser
besides the requisite Subject and From lines.
Right now they're being echoed onscreen for my own purposes of
testing, but either way I can't get it all into the form that's sent to
me. I've been playing with this off & on for a week now and guess I need
help!

Can anyone advise me how to accomplish my goal?

TIA,

Twayne`
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: DIY finger tip typin - pace and code, (PHP open source)
Next Topic: tracking IP's
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 28 00:54:03 GMT 2024

Total time taken to generate the page: 0.04491 seconds