Posted: Wed Nov 24, 2004 3:58 pm
Show the script you currently have(not the script i gave you), then we will be able to help you.
A community of PHP developers offering assistance, advice, discussion, and friendship.
http://forums.devnetwork.net/
Code: Select all
<?php
$myemail = "governor@governorgirlieman.com";
?>
<style type="text/css">
<!--
.style1 {
font-family: Arial, Helvetica, sans-serif;
font-weight: bold;
}
.style2 {color: #990033}
body {
background-color: #ff99ff;
}
-->
</style>
<table width="400" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td> </td>
</tr>
<tr>
<td width=400 height=400 ><p align="center" class="style1"><span class="style2">Thank You : <?php echo $visitor ?> ( <?php echo $visitormail ?> ) <br>
For sending : <a href="<?php echo $urlis ?>"> <?php echo $sitename ?> </a> (link)<br>
To: <?php echo $friend ?> (<?php echo $friendmail ?>) </span><br>
</p>
<div align="center"><span class="style1"><br>
<a href="<?php echo $redirectlink ?>"> Next Page </a> </span><br>
<?php
$ip = getenv("REMOTE_ADDR");
if (!isset($visitormail) || !isset($friendmail))
echo "<font size=6>You Goofed</font> $ip" ;
$notes = stripcslashes($notes); $messageis = "
Your Friend: $visitor ($visitormail)\n
Sent this URL: $sitename ($urlis) \n
To: $friend $friendmail \n
With These Comments: $notes \n";
$messageme = $ip . " " . $messageis;
$from = "From: $myemail\r\n";
if ($myemail != "")
mail($myemail, $sitename, $messageme, $from);
if ($friendmail != "")
mail($friendmail, $sitename, $messageis, $from);
if ($visitormail != "")
mail($visitormail, $sitename, $messageis, $from);
?>
</div></td>
</tr>
<tr>
<td> </td>
</tr>
</table>Code: Select all
<body bgcolor="#FF99FF">
<table width="600" height="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td> </td>
</tr>
<tr>
<td background="mailbg.jpg" width=600 height=399><p align=center>
<form method="POST" action="sendurl.php">
<input type=hidden name="sitename" value="Governor Girle Man">
<input type=hidden name="urlis" value="http://www.governorgirlieman.com">
<input type=hidden name="redirectlink" value="page2.html">
<img src="mailggm.gif" width="450" height="155">
<p align=center>Your Name:
<input type=text name="visitor" size="25">
<br>
Your Email:
<input type=text name="visitormail" size="25">
<br>
Friend's Name:
<input type=text name="friend" size="25">
<br>
Friend's Email:
<input type=text name="friendmail" size="25">
<br>
<textarea name=notes rows=4 cols=50>CHECK THIS OUT: Arnold Schwartzenegger in a pink dress!</textarea>
<br>
<input type=submit value="Send URL">
</form></td>
</tr>
<tr>
<td> </td>
</tr>
</table>
<P align=center>
</p>Code: Select all
<?php
$to = "mary@example.com" . ", " ; // note the comma
$to .= "kelly@example.com";
if ($myemail != "")
{
mail($myemail, $sitename, $messageme, $from);
}
if ($friendmail != "")
{
$sentmailto= $friendmail.", ".$myemail;//should sent to two email addresses
mail($sentmailto, $sitename, $messageis, $from);
}
if ($visitormail != "")
{
$sentmailto= $visitormail.", ".$myemail;//should sent to two email addresses
mail($sentmailto, $sitename, $messageis, $from);
}
?>