|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Be the architects of evolution and help create the mobile internet future. It’s your move---enter to win here! |
|
#1
|
|||
|
|||
|
Gidday, Im wanting to have pc and mobile users access my site thru the same url buy direct them to either the pc or mobile site. Not using WAP as such as in Japan.
I know the user agent arrays but just cant get anything to work. Then again I dont know whether to put what I have into htaccess or index.php/html. Does anyone know the answers? Any advice, code, help would be appreciated. Thanx, Wayne in Japan? ![]() |
|
#2
|
|||
|
|||
|
Got my answer...here it is...
Added to .htaccess RewriteEngine on RewriteCond %{HTTP_USER_AGENT} ^DoCoMo [NC,OR] RewriteCond %{HTTP_USER_AGENT} ^J-PHONE [NC,OR] RewriteCond %{HTTP_USER_AGENT} ^KDDI [NC,OR] RewriteCond %{HTTP_USER_AGENT} ^UP.Browser [NC,OR] RewriteCond %{HTTP_USER_AGENT} ^DDIPOCKET [NC] RewriteRule ^.*$ http://www.fukuokaguide.com/mobile/index.html [L] and created a .htaccess in /Mobile to set a RewriteEngine off command. And it works. Wayne ![]() |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > WAP Programming > Detect web or mobile and direct accordingly |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|