|
|
|
#1 |
|
Messages: n/a
Hébergeur: |
When $component_reference is 5 or 19 I don't want the echo statement to
output to the screen. What is the correct syntax? What I have below isn't working. Thanks for your . Ron if ( ($component_reference != "5") OR ($component_reference != "19") ) { echo "<li><a href=\"index.php?request=" . $request . "\">" . $component_name . "</a>"; } |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
Hi, here is the code:
if ( ($component_reference != "5") AND ($component_reference != "19") ) { echo "<li><a href=\"index.php?request=" . $request . "\">" . $component_name . "</a>"; } 2007/10/19, ron.php <ron.php@actsministries.org>: > When $component_reference is 5 or 19 I don't want the echo statement to > output to the screen. What is the correct syntax? What I have below isn't > working. Thanks for your . Ron > > if ( ($component_reference != "5") OR ($component_reference != "19") ) { > echo "<li><a href=\"index.php?request=" . $request . "\">" . > $component_name . "</a>"; > } > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > |
|
|
|
#3 |
|
Messages: n/a
Hébergeur: |
Are you sure that the value is a string? If its numeric, then try the checkwithout the quotes around the value bastien> From: ron.php@actsministries.org> To: php-general@lists.php.net> Date: Thu, 18 Oct 2007 19:49:55 -0500> Subject: [php] IF command> > When $component_reference is 5 or 19 I don't want the echo statement to > output tothe screen. What is the correct syntax? What I have below isn't > working.Thanks for your . Ron> > if ( ($component_reference != "5") OR ($component_reference != "19") ) {> echo "<li><a href=\"index.php?request=" . $request . "\">" . > $component_name . "</a>";> }> > -- > PHP General Mailing List (http://www.php.net/)> To unsubscribe, visit: http://www.php.net/unsub.php> __________________________________________________ _______________ Send a smile, make someone laugh, have some fun! Start now! http://www.freemessengeremoticons.ca/?icid=EMENCA122 |
|
![]() |
| Outils de la discussion | |
|
|