₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,330,535 members, 8,445,926 topics. Date: Wednesday, 15 July 2026 at 06:41 PM

Toggle theme

How To Create A Mobile Subdomain For My Site - Webmasters - Nairaland

Nairaland ForumScience/TechnologyWebmastersHow To Create A Mobile Subdomain For My Site (930 Views)

1 Reply (Go Down)

How To Create A Mobile Subdomain For My Site by davidgn(op): 7:47pm On Mar 07, 2019
Please can someone help me with Steps on how to create an m.mysite.com subdomain and make it Use the same database and files in the main website.

Please guys help me
Re: How To Create A Mobile Subdomain For My Site by resosdigital(m): 7:56pm On Mar 07, 2019
davidgn:
Please can someone help me with Steps on how to create an m.mysite.com subdomain and make it Use the same database and files in the main website.

Please guys help me
There is really no reason to tow this path.

You should instead make your website responsive so it can adjust to any screen size and device the user is using
Re: How To Create A Mobile Subdomain For My Site by davidgn(op): 10:55am On Mar 10, 2019
I know about Responsiveness, my current theme is responsive but it's not what i want for my mobile users.

I want to load a different theme for my mobile users.
I believe subdomain will be best for that.

Please just give me clue how to go about it.
Thanks
Re: How To Create A Mobile Subdomain For My Site by mcqwerty(m): 8:07pm On Mar 10, 2019
Use JQuery mobile.
There should be a code that detects if the user is using a mobile browser and redirects to the mobile site.
Re: How To Create A Mobile Subdomain For My Site by davidgn(op): 10:08pm On Mar 10, 2019
mcqwerty:
Use JQuery mobile.
There should be a code that detects if the user is using a mobile browser and redirects to the mobile site.
Please, before I do the redirecting, how do I setup the subdomain and make it Use the same database and files with the main domain.
Re: How To Create A Mobile Subdomain For My Site by paolouzo: 1:15am On Mar 11, 2019
I feel creating a subdomain is unnecessary; I'd advise you use a subfolder instead.

If you don't mind a /mobile or /mobi (for example www.me.com/mobile or www.me.com/mobi) then all you need do is load your preferred theme in a subfolder named mobile or mobi then add a redirect code in the head tag of your root index page.

Now, this redirect code will make use of screen size so once you visit with a screen size smaller than specified, it automatically re-routes you to the subfolder.

Eg if your redirect code specifies width of less than 500px, any device with a width lower than 500px will be directed to the subfolder. So if I enter www.me.com on a mobile phone, I will be taken automatically to www.me.com/mobile and my view will be the theme loaded there.

Your redirect code should be set for not more than 1 second so it's very fast and your visitor wouldn't notice.

That's what I did for www.yungblnkz.com you can try it out to see for yourself.

Hope this helps!
Re: How To Create A Mobile Subdomain For My Site by davidgn(op): 7:23am On Mar 11, 2019
paolouzo:
I feel creating a subdomain is unnecessary; I'd advise you use a subfolder instead.

If you don't mind a /mobile or /mobi (for example www.me.com/mobile or www.me.com/mobi) then all you need do is load your preferred theme in a subfolder named mobile or mobi then add a redirect code in the head tag of your root index page.

Now, this redirect code will make use of screen size so once you visit with a screen size smaller than specified, it automatically re-routes you to the subfolder.

Eg if your redirect code specifies width of less than 500px, any device with a width lower than 500px will be directed to the subfolder. So if I enter www.me.com on a mobile phone, I will be taken automatically to www.me.com/mobile and my view will be the theme loaded there.

Your redirect code should be set for not more than 1 second so it's very fast and your visitor wouldn't notice.

That's what I did for www.yungblnkz.com you can try it out to see for yourself.

Hope this helps!
Okay thanks, I'll try that.
But I think it's almost the same thing with subdomain.
From what I've read so far online, subdomain has more SEO advantages than subfolder

Thanks anyway, I appreciate your help
Re: How To Create A Mobile Subdomain For My Site by etoluw: 8:33am On Mar 11, 2019
davidgn:
Please can someone help me with Steps on how to create an m.mysite.com subdomain and make it Use the same database and files in the main website.

Please guys help me
are you using wordpress?
Re: How To Create A Mobile Subdomain For My Site by davidgn(op): 10:23pm On Mar 11, 2019
etoluw:
are you using wordpress?
No sir.
I'm using osclass.
1 Reply

How To Create Subdomain In BloggerGoogle Adsense Account For Sales With SubdomainBoost Your Site Traffic Even With A Subdomain Name234

Can U Host A Designed Website On Google?Last DAY! Get Your .COM Domain At N2,116/1st YrWho Is Using Avast Secureline VPN ? (share Your Experience)