jibilkv
September 15th, 2006, 12:17 AM
I have created a mail function for sending an html newsletter. And in that mail the body part of the mail function contains a function for popuping a window. This function contains single quotes . And since the body part of the mail function is inside the single quotes the single quotes in the function is not functioning. For that i created a variable for this single quote and included this variable in the place of sigle quotes. Still the function is not working. I get the popup window with toolbars and as normal window.
I am including the code along with this. Is there any alternative for this.????.....:upset:
The line with the problem is displayed between <------------->
This is the code format i used for newsletter sending
==============
<?
$subject=$_POST['txtsubject'];
$mail_to= $email;
$mail_subject=$subject;
$bodycontent='<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<table width="624" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td><table width="100%" border="0" cellspacing="0" cellpadding="0" class="">
<tr>
<td valign="top" class="text1"> <br> <br>
<---------->
<a href="sample link.htm" target="_blank" onclick="window.open(this.href, this.target,'toolbar=no,scrollbars=yes,location=no ,status=yes'); return false;" title=" Description of link " class="content">read more</a>
<---------->
</td>
</tr>
</tr>
</table>
</BODY>
</html>';
$headers = "From: test< test@mail.com >\n"; //headers from address
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\n";
mail($mail_to,$mail_subject,$bodycontent,$headers) ;
?>
========================================
the problem is that when i clicked the "read more" link pop window opens like a html web page with toolbars
I am including the code along with this. Is there any alternative for this.????.....:upset:
The line with the problem is displayed between <------------->
This is the code format i used for newsletter sending
==============
<?
$subject=$_POST['txtsubject'];
$mail_to= $email;
$mail_subject=$subject;
$bodycontent='<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<table width="624" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td><table width="100%" border="0" cellspacing="0" cellpadding="0" class="">
<tr>
<td valign="top" class="text1"> <br> <br>
<---------->
<a href="sample link.htm" target="_blank" onclick="window.open(this.href, this.target,'toolbar=no,scrollbars=yes,location=no ,status=yes'); return false;" title=" Description of link " class="content">read more</a>
<---------->
</td>
</tr>
</tr>
</table>
</BODY>
</html>';
$headers = "From: test< test@mail.com >\n"; //headers from address
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\n";
mail($mail_to,$mail_subject,$bodycontent,$headers) ;
?>
========================================
the problem is that when i clicked the "read more" link pop window opens like a html web page with toolbars