February 2, 201115 yr Hey everyone! I'm developing a site at the moment and the client wants a mobile version - I've never done this before. Ideally, this mobile version will automatically display when the user first visits (on iPhone, Android etc) and there will be a link on that mobile page to the full site (in case they want that instead). I've had a play with css media queries using max-device-width and min-device-width and this kind of works. Well, what I mean is that when I view the site on a mobile device such as an iPhone, it uses the mobile stylesheet (I have one for portrait and one for landscape). The only problem with this is that I don't know how to offer the option to view the full 'non-mobile' site from within the mobile site. Could I just switch the stylesheet from within the page? If so, how do I do this. Does that make sense? Sorry if it doesn't
February 2, 201115 yr Just use a cookie or a session to prevent the mobile version running if they've selected not to use it.
February 3, 201115 yr You could always set up a mobile landing page like this: http://buildinternet.com/2011/01/add-a-mobile-landing-page-to-your-site/?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed:+buildinternet+(Build+Internet!) ...and offer buttons to view either full site or mobile site. Here's a good way of switching stylesheets: http://www.alistapart.com/articles/alternate/ Hope that helps
February 9, 201115 yr Author You could always set up a mobile landing page like this: http://buildinternet.com/2011/01/add-a-mobile-landing-page-to-your-site/?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed:+buildinternet+(Build+Internet!) ...and offer buttons to view either full site or mobile site. Here's a good way of switching stylesheets: http://www.alistapart.com/articles/alternate/ Hope that helps Thanks for the reply, I really appreciate it. I tried the code from the first page you recommended (buildinternet) and it works great on my iPhone 4 but I have three friends with Android devices who have tried it and, despite it being 'meant to work' on them, they don't get redirected. This has led me to look into server-side redirects but there's so much information out there - it's difficult as I'm no PHP developer. I've seen people recommending methods like this but if the redirect is done 'server-side' then how would I get the user to be able to view the full site from the mobile site. I guess I'd need some kind of cookie but this is way past my knowledge level
Create an account or sign in to comment