[snip]
If I use this on index.html, it does nothing.  If I use it on index.php
I get:

Parse error: parse error, unexpected '=' in 
/path/to/file_named/main.php on line 3

What am I doing wrong


On Tuesday 17 June 2003 02:11 pm, Ralph wrote:
> <?php
>
> if(strstr = ($HTTP_USER_AGENT, "Mozilla/4")){
>    header("Location: http://www.mydomain.com/moz4_page.php";)
> }
>
> elseif(strstr = ($HTTP_USER_AGENT, "MSIE")){
>    header("Location: http://www.mydomain.com/ie_page.php";)
> }
>
[/snip]


Shouldn't it  be ....
> if(strstr($HTTP_USER_AGENT, "Mozilla/4")){
>    header("Location: http://www.mydomain.com/moz4_page.php";)
> }
>
> elseif(strstr($HTTP_USER_AGENT, "MSIE")){
>    header("Location: http://www.mydomain.com/ie_page.php";)
> }

HTH

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to