sebarmeli/JS-Redirection-Mobile-Site

Ipad Redirect

Closed this issue · 4 comments

With respect to this Script:

<script> SA.redirection_mobile ({ mobile_url : "whatever.com/example", mobile_prefix : "https" }); </script>

Where must the tablet redirect line be placed, thus far its inclusion depending on placement has either not worked, or in the worst case caused it to stop redirecting mobile phones as well.

Is there a way in the Redirection-Mobile.JS code to change the default to redirect tablets as well? (I am fairly new to javascript)

Thanks

Hi George,

You should call the function in this way :
SA.redirection_mobile ({ mobile_url : "whatever.com/example", mobile_prefix : "https", 'tablet_redirection : "true" });

Do you have a URL so I can see what's wrong with it?

Cheers,
Sebastiano

What if I would like to redirect tablets to one place and mobile phones to another? I am currently using....

<script src="/js/redirection_mobile.js"></script> <script> SA.redirection_mobile ({ mobile_url : "mysite.com/mobile/index.php", mobile_prefix : "http", }); </script>

I may add a new parameter called "tablet_url" in case you need to specify a certain url for tablets

fixed in version 0.9.5 just released