[thelist] Quoted attibute values
Jay Fitzgerald
jayfitz at bayou.com
Mon Jan 15 18:35:31 CST 2001
from what i understand...if you use
echo "
then all of your double quotes must be \'ed out....and you may use
single-quotes unless -
if you use
echo '
then the opposite is true....
HTH
Jay
John Kershaw wrote:
> >Plus, it only takes a fraction of a second to add the quotes, and it makes
> >your code more readable...
>
> Here's something I've been meaning to find out: does it matter
> whether I use single or double quotes?
>
> I know the specs say either, but everyone (?) uses double quotes, and
> when I'm echo'ing html tags from PHP, it's a darn sight easier to use
> single quotes than escaped double ones:
>
> a) echo "<img src='blob.jpg'>"; // better?
> b) echo "<img src=\"blob.jpg\">"; // worse?
>
> plus my html editor is a lot happier with a) than b)
>
> Your thoughts?
>
> John.
>
> ---------------------------------------
> For unsubscribe and other options, including
> the Tip Harvester and archive of TheList go to:
> http://lists.evolt.org Workers of the Web, evolt !
--
Jay Fitzgerald - Web Development/Sales
=============================================
Bayou Internet http://www.bayou.com
Mississippi Internet
http://www.mississippi.net
Vicksburg Online http://www.vicksburg.com
Bama Online http://www.bamaonline.net
=============================================
ICQ: 38823829 Phone: 888-302-2968 Fax: 877-329-2296
More information about the thelist
mailing list