RE: [PHP] how to set font colors
| From: | Matthew Loff | Date: | Sun, 14 Oct 2001 05:13:05 +0000 |
| Subject: | RE: [PHP] how to set font colors | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-71017@lists.php.net to get a copy of this message | ||
If you use double quotes to enclose a string literal, as you did in your
example, PHP sees the double quotes in the <FONT> tag, and thinks you
are trying to close the string, thus the syntax error.
You have to escape the double quotes with a backslash character, e.g.:
echo "
<dl><dt><b><font color=\"#FFFFFF\">$user[0]</font></b>
$mailadd $urladd ($user[3])<dt><dd>$user[4]<
/dd>\n</dl>";
-----Original Message-----
From: Regis Philbin [mailto:regis@nbc.com]
Sent: Sunday, October 14, 2001 12:53 AM
To: php-general@lists.php.net
Subject: [PHP] how to set font colors
I'm trying to modify some font collors. The author has indicated that I
just
need to insert standard markup tags. Below, is the unmodified code.
echo "
<dl><dt><b>$user[0]</b> $mailadd $urladd ($us
er[3
])
<dt><dd>$user[4]</dd>\n</dl>";
the normal font tags like the example below return an error.
<font color="#FFFFFF">$user[0]</font>
Is this done differently in php?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net