Re: Shopping with variables

From: Date: Wed, 16 May 2001 09:39:29 +0000
Subject: Re: Shopping with variables
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-53004@lists.php.net to get a copy of this message
Hello Tarrant, Wednesday, May 16, 2001, 12:12:43 PM, you wrote: TC> <?php print(" You have asked to purchase $dvd $video $cd 's - Thank you") TC> >? TC> This prints out, "You have bought 16 - Thank you" for example, see the TC> problem? How do I get it to print the variable name not just it's value? Use <?php print(" You have asked to purchase ". ($dvd ? "DVD: $dvd ":''). ($video ? "Video: $video ":''). ($cd ? "CD's: $cd ":''). " - Thank you") ?> -- Best regards, Vitali mailto:falileev@itos.eu.org

« previous php.general (#53004) next »