NamePros.Com (http://www.namepros.com/)
-   Programming (http://www.namepros.com/programming/)
-   -   [resolved] simple php help (http://www.namepros.com/programming/455307-resolved-simple-php-help.html)

champ_rock 04-08-2008 09:51 PM

simple php help
 
PHP Code:
<?php
if ($pageURL === "abc.com" ||  "xyz.com" || "pqr.com" || "aer.com")
  {
echo
'something';
}
?>


helo.

i am looking to create some snippet which basically does the following work
1. the $pageURL string contains this $_SERVER["SERVER_NAME"] (the domain of the page)
2. i want to match it up with few matches and output something in particular if the $pageURL is same as the above four matches. and not echo anything when $pageURL is different from the above 4.

but when i am using this code, it is echoing "something" in every domain, even in lets say "blahblah.com" and "tommy.com". the logical comparison is not working :(


any suggestions where i am going wrong?

never mind.. i solved it :)


All times are GMT -7. The time now is 12:17 AM.
Site Sponsors
Advertise your business at NamePros

Powered by: vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0