Not compatable with iphones, yet I was told it was!
Autor: Dave E.
Besucht 2055,
Followers 2,
Geteilt 0
I have raised this issue many months ago and it wasnt sorted and now with more people using portable devices to search the internet I need to sort this out once and for all.
X5 has normal templates and mobile templates, in the sales patter it states that the normal templates are compatible with iphones etc. When I asked some time ago as to why they had seperate mobile templates when normal templates would suffice nobody could say.
So now I want to create a mobile template with a very limited script and I want to know how to link it to my normal website, (if its possible) so that when people search with mobiles it can detect this and direct them to the mobile listing.
Gepostet am
Dave, there are 2 ways to do so
1- using java code: go to general setting>expert tab and place this code on "befor closing the HEAD tag"
<script type="text/javascript"> <!-- if (screen.width <= 800) { [removed] = "http://m.domain.com"; } //--> </script>
m.domain.com has been used as example, change that with the actual address.
or
2- go to your server root and open the file called .htaccess and place the following code inside that file
RewriteEngine On
# Check for mime types commonly accepted by mobile devices
RewriteCond %{HTTP_ACCEPT} "text\/vnd\.wap\.wml|application\/vnd\.wap\.xhtml\+xml" [NC]
RewriteCond %{REQUEST_URI} ^/$
RewriteRule ^ http://m.domain.com%{REQUEST_URI} [R,L]
and same here, m.domain.com used as example, change that with the actual address.
GL
Autor
Thanks for the reply.
Number one sounds easy for me. However,are you suggesting that placing this code will alter the appearance of my existing site when accesed by a mobile or do i still need to create another website and if this is the case what do I call it, ie how to link it.
Thanks for any help.
David
No, you need to create mobile version of your website, then upload it to a folder or subdomain like m.yourdomain.com, after placing the code, visitors who use mobile will see your mobile version automatically
Autor
This is what iv'e added but it still goes to the main site. Was I supposed to replace the text where it says [removed] ? Thanks Dave
<script type="text/javascript">
<!-- if (screen.width <= 800) { [removed] = "http://www.seaforth-blackpool.co.uk/mobile"; } //--> </script>
Hello Dave,
It should be window . location without space before and after the dot but to be sure wait for the reply of Anthony.
Many thanks!
Autor
"" window . location without space before and after the dot ""
sorrry for my ignorance but before what dot?? and is the wording " window . location "
Dave
Hello Dave,
I meant the space between the words window and location. There needs to be no space and only a dot to separate them.
In any case wait for the reply of Anthony to be sure the code is correct since we do not give support to custom HTML code.
Many thanks!