How to serve a Mobile & Full Site using one URL?
-
Hello,
Does anyone know of any resources or tutorials that outline how to serve a smartphone-formatted website using the same URL as the full site?
I know that one solution is using media-queries to serve a seperate CSS stylesheet, but you still have the full HTML source code. In other words, I might want to serve a smartphone & desktop user different content, but under one URL.
WP Touch (Wordpress Plugin) is a perfect example of what I mean, but how is it technically achieved? It serves two different sets of HTML for smartphone & full, but using one URL
-
No, I am also in the process of enquiring, I program in ASP.Net MVC, and the new MVC4 comes with a few starter templates (with Visual Studio 2010), this is where i got the info i suggested.
I can send you a starter template if you like, you can have a look though if you like. Actualy you will need VS2010 to run it, you can down load a trial but then you may as well download MVC4 as well.
-
Hi Alan,
Thanks very much, I agree - it likely would be easier to use media queries, but I am looking for that ultimate fix and insight on how others do it
-
Then of cause you would need to use a server side solution, this is quite simple in therory, all you need to do is get the severvariable HTTP_USER_AGENT to detect the browser, but then there would be a lot of different serveragenst to detect and more in the future. It would also be a pain having to generate html via server script for every page. I tried doing that for Netscape 2 and IE2 but gave up, it was too much work. Back in those days the way of doing things in browsers was completely different untill IE won out.
I think the eay i was saying is much easier, and there is no missing html, its all used on both versions just positioned different.
-
Hi Alan,
As mentioned. I'm not looking for a CSS solution, but rather a HTML one where different HTML is served if the user-agent is a smartphone.
CSS Media Queries can work in some situations, but not for all. For example, taking the following page - http://www.flybmi.com/bmi/en-gb/index.aspx - and using a mixture of CSS and display none; to output http://www.flybmi.com/mobile would result in a mobile site full of hidden/wasted code.
-
I have a few examples. i used the tag in the head section of the html.
Along with Media css see below. you slip this css into your normal css sheet, and give an alternitive css inside for phones,
if you look at one of my sites http://perthseocompany.com.au/ i have done like this you will notice that when the screen size goes below 850px it then takes on the alternative css. One of the main things you will want to do is make sections of your website line up verticly under the alternitive. You can do this by using float left and float right in normal site and float none in alternative css.
I do not have my site perfect because i have not yet had the time. but you get the general idea by playing with browser width.
Note the max-width: 850px in css, this is the width at witch the css changes@media only screen and (max-width: 850px)
{header .float-left, header .float-right
{
float: none;
}
} -
Hi Tommy,
This doesn't provide any technical answers unfortunately, and refers to mobile devices as opposed to smartphones. Googlebot-mobile is designed for WAP/iMode etc. style websites, Google on smartphones, tablets etc. displays the same results as the desktop version.
-
Hi Pete!
Take a look in Googles SEO guide on page 26, http://static.googleusercontent.com/external_content/untrusted_dlcp/www.google.com/en//webmasters/docs/search-engine-optimization-starter-guide.pdf
Good luck!
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Is it okay to design different mobile site for different browsers
Hi, Is it okay to design different mobile site for different browsers on same url. The content of the site will also be different on different browsers. Will it be treated as black hat by Google. The mobile site & desktop site has same url across devices & browsers. Regards
Web Design | | vivekrathore0 -
Is there any negative SEO effect when using Wordpress for your Blog?
I have a site entirely done in html, no CMS used. The blog page however, is wordpress. Wondering if this will effect us negatively in terms of SEO, having the blog that is linked to our site, a wordpress site. My gut is absolutely not, but the questions was asked....what do you think?
Web Design | | cschwartzel0 -
New site - same host domain?
Building a new site for my business (different URL) For SEO purposes...Is it ok to host the site on the same account as my existing site (GoDaddy) or should I purchase a seperate hosting account? Thanks
Web Design | | Tustep0 -
Avoiding duplicate content with multi-lagusage site
Hi, We have a client in China that is looking to create three versions of the same website, English, Chinese and Korean. They do not want to use a translation plugin like Google translate, preferring to have the pages duplicated. What is the best way to do this bearing in mind that the site needs to be found in all three languages. Would also appreciate if anyone knows of a good hosting company that has English support on the Chinese main land. Thanks Fraser
Web Design | | fraserhannah0 -
One big page vs. multi-step pages
Hi mozers! Brand new to SEO and LOVING it! Having several key questions that I don't see answered yet, but I'll start with one we've been very curious about. Consider this guide we have for Forming a Delaware Corp.
Web Design | | Mase
https://www.upcounsel.com/Free-Legal/Guide/17/Form-A-Delaware-Corporation This is our overview page, giving you a breakdown of what this process involves. We love this page, but (Question1:) does it lack better real "content" rather than lots of links to the guide process itself? Then, you can start to walk through the guide beginning with step one, where each step has crowd sourced answers to it. But as you see, the step pages are all very similar, except for the answers and step info. (Question 2) Would it be better to put all our answers into the one overview page and skip having separate pages for each step? We like the process and simplicity of seeing one step at a time, but then these pages don't seem to have enough unique content on them. Related, at what point (if any) is a page too big with too much content and considered bad for SEO? We're recovering from a big hit from Google, and slowly recovering by nailing down various SEO mistakes. We DO have great, unique and valueable content - now we just need it to rank!0 -
URL structure for multiple cities?
Hi, i am in the process of setting up a business directory site that will be used in a number of cities, though i am initially launching with only one city. My question is, what is the best URL structure to use for the site and should i start using this URL structure from day one? At the moment i am using www.mysite.com.au as my primary website where it contains all listings for the the one initial launch city. Though to plan for the future i was considering this URL structure: www.mysite.com.au/cityname so for example, if i launch in the city Sydney initially then all website traffic that goes to www.mysite.com.au would simply be redirected (302 temp redirect?) to www.mysite.com.au/sydney. When i expand to other cities www.mysite.com.au would simply be a "select your city" screen that then redirects to the city of choice (similar to www.groupon.com page). How would doing a 302 redirect from www.mysite.com.au to www.mysite.com.au/city impact on SEO for the initial launch? Or should i just place this on the root domain since no other cities exist at the moment?
Web Design | | adamkirk0 -
Basekit.com anybody using it?
I need help to built a mulitlanguage website. After posting questions, I most admit Wordpress with a premium template might be the options for all the features I need. Thoses are: SEO Frendly (custom links...html...Alt Tag...Metadata...)
Web Design | | BigBlaze205
Mobile Version
Great Template
Multilanguage Complete web site
Google Analytics
Blog
301 redirect Some one suggest basekit.com Do you thing it might be my solution? Thank you for your help. BigBlaze0