Clean URLS for web n wap interfaces

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
hmvrulz
Forum Newbie
Posts: 20
Joined: Fri Oct 03, 2008 10:20 pm

Clean URLS for web n wap interfaces

Post by hmvrulz »

Can some one help me in deciding the best way to code clean urls for web as well as wap


WEB

site.com/modules/action/id (if needed)

WAP

site.com/modules/action/id/mobile
User avatar
aceconcepts
DevNet Resident
Posts: 1424
Joined: Mon Feb 06, 2006 11:26 am
Location: London

Re: Clean URLS for web n wap interfaces

Post by aceconcepts »

mod_rewrite?
hmvrulz
Forum Newbie
Posts: 20
Joined: Fri Oct 03, 2008 10:20 pm

Re: Clean URLS for web n wap interfaces

Post by hmvrulz »

no... am asking how to frame my urls... logical help not php


problem is incase there is no ID

it wil become

site.com/modules/action/mobile
for wap


then its waste of resources to check each time if its a id or mobile
User avatar
Eran
DevNet Master
Posts: 3549
Joined: Fri Jan 18, 2008 12:36 am
Location: Israel, ME

Re: Clean URLS for web n wap interfaces

Post by Eran »

mobile should come first, logically

Meaning:

site.com/modules/action/id

And:

site.com/mobile/modules/action/id
User avatar
requinix
Spammer :|
Posts: 6617
Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA

Re: Clean URLS for web n wap interfaces

Post by requinix »

Why not have a mobile subdomain? mobile.site.com is friendlier than site.com/mobile and you don't have to worry about changing links to point to /mobile instead.
hmvrulz
Forum Newbie
Posts: 20
Joined: Fri Oct 03, 2008 10:20 pm

Re: Clean URLS for web n wap interfaces

Post by hmvrulz »

But am using my own MVC framework... basically if its mobile site i wil only have a different view.... to make it compatible with the mobile devices
User avatar
onion2k
Jedi Mod
Posts: 5263
Joined: Tue Dec 21, 2004 5:03 pm
Location: usrlab.com

Re: Clean URLS for web n wap interfaces

Post by onion2k »

Surely how you actually implement the URLs is unimportant compared to how usable it is for the user? Having /mobile at the end of the URL is going to be a hassle for anyone inputting the location on a phone that's geared towards inputting standard mobile URLs such as mobile.domain.com, m.domain.com or domain.mobi?
Post Reply