Reply to Re: interpolating variables

Your name:

Reply:


Posted by slimdizzy on 08/04/06 18:24

magic_hat60622 wrote:
> hi all. I have an html file that I need php to read and send as an html
> e-mail. The file contains standard html and also some variable names
> that I want php to interpolate:
> <html>
> Hi there. my name is $name
> </html>
>
> I'm reading the file like so:
> $fh=fopen('./emails/confirmation/index.html', 'r') or die
> ($php_errormsg) ;
> while (! feof($fh)){
> $body.=fread($fh,filesize('./emails/confirmation/index.html'));
> }
>
> PHP is not interpolating the variable names in the email. Solutions?
>
> -Magic

Why not just put the html of the message you want to send into a
variable in that script??
Are there reason why your reading a file for such a small amout of
text/html??

Just seems to be more work then needed unless you have users making
these files and want them to be in a static place for your script to
read from.

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация