Warrior Forum - The #1 Digital Marketing Forum & Marketplace

Warrior Forum - The #1 Digital Marketing Forum & Marketplace (https://www.warriorforum.com/)
-   Mobile Marketing (https://www.warriorforum.com/mobile-marketing/)
-   -   mobile redirect scripts (https://www.warriorforum.com/mobile-marketing/629192-mobile-redirect-scripts.html)

pierrebenoit 3rd July 2012 12:20 AM

mobile redirect scripts
 
Hi,
I would like to know how to test a mobile redirect script.
I've put one in a main website and I can't go to the mobile website using an iphone simulator. I've use mobiliser software without success.
The redirect script use javascript
Any help?

Thanks

Jay Moreno 3rd July 2012 12:47 AM

Re: mobile redirect scripts
 
Hi Pierre,

I am thinking your redirect script is using screen size detection if this is the case mobilizer will not pass the proper screen size to your script, instead am thinking your script is picking up your actual desktop screen size.

If you are using screen size detection change the width to be more than your desktop resolution whilst testing with mobilizer

Best way to test is on an actual real handset - if you don't have access to one try perfecto mobile.com

Hope that helps

Jay

gabbo 12th July 2012 05:23 AM

Re: mobile redirect scripts
 
If you don´t have a mobile phone on hand just install Ref Agent Switcher Addon for Firefox. Almost any mobile redirection script checks for the browser agent so this should do the job.

Jay Moreno 12th July 2012 07:15 AM

Re: mobile redirect scripts
 
Quote:

Originally Posted by gabbo (Post 6594946)
If you don´t have a mobile phone on hand just install Ref Agent Switcher Addon for Firefox. Almost any mobile redirection script checks for the browser agent so this should do the job.

You will be surprised many people still use screen size detection for redirecting, I wish people would user agent redirection, would be easier to detect! :)

therealtiger 13th July 2012 08:39 AM

Re: mobile redirect scripts
 
Quote:

Originally Posted by pierrebenoit (Post 6538910)
Hi,
I would like to know how to test a mobile redirect script.
I've put one in a main website and I can't go to the mobile website using an iphone simulator. I've use mobiliser software without success.
The redirect script use javascript
Any help?

Thanks

Hi,
Can you let me know what are you doing in detail with the code so that i can help you. Might me there something wrong in your code i guess.

WillR 22nd July 2012 10:47 PM

Re: mobile redirect scripts
 
Yes, Jay is correct. Screen size detection will not work on an emulator. The same way a flash website will show fine on an emulator but not an iPhone. The emulator is using your computers resources.

JohnE 23rd July 2012 10:08 AM

Re: mobile redirect scripts
 
Quote:

Originally Posted by pierrebenoit (Post 6538910)
Hi,
I would like to know how to test a mobile redirect script.
I've put one in a main website and I can't go to the mobile website using an iphone simulator. I've use mobiliser software without success.
The redirect script use javascript
Any help?

Thanks

You should use a PHP user agent script. It is a much more robust way to detect mobile devices. Javascript, with regards to mobile device detection, is precarious at best.

John

brianng 5th August 2012 03:42 PM

Re: mobile redirect scripts
 
I've been using this https://github.com/sebarmeli/JS-Redirection-Mobile-Site for my 3 sites and they work just fine. What iphone simulator are you using? Use their DOM inspector.


All times are GMT -6. The time now is 04:15 PM.