You are here: Re: Why can't I create the string "User" <user@inter.net> « All PHP « IT news, forums, messages
Re: Why can't I create the string "User" <user@inter.net>

Posted by Oli Filth on 11/23/05 18:47

Stefan Mueller wrote:
> > if you view the source of the resulting page you will find that
> > <user@inter.net> is there... your browser is interpreting it as an
> > html tag (although not a valid one) and not displaying it... if you
> > want to display it use &lt; and &gt; rather than < and >
> >
> > as far as using the mail() function - the string $header you have
> > created will work
>
> I tried it almost the whole night - without success. Now I get
> From: "User" <user@inter.net>
> and that's really what I like to have. Many thanks.
>
> Hmmm, I don't exactly understand why my browser was interpreting it as a
> html tag. I think a PHP is running on the server side and not on the browser
> side. Isn't it?

PHP echoes the string 'From: "User" <user@inter.net>', which is sent to
the browser.

Browser receives this, and tries to interpret it as HTML (assuming page
has been delivered with text/html header).

In HTML, by definition, anything within < > is interpreted as a markup
tag (even if it's an invalid tag), and therefore isn't shown.

--
Oli

 

Navigation:

[Reply to this 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

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