![]() |
| Search Engine Safe URLs (SES) |
|
Jason101
Forum Regular
|
I know there are 4 other threads in the forum regarding this topic, but they are outdated, so I'm revisiting the topic.
I using a SESConverter to change the following url http://www.example.com/Product.cfm?Prod=11577857 to http://www.example.com/Product.cfm/Prod/11577857 But as mentioned by some else, the extension(.cfm) still exist on the middle of URL It would be nice to make it look like: http://www.example.com/Product/11577857 How, I know HostMySite's URLS are something like.. http://www.hostmysite.com/hosting/vps/windows/cf/ Now I would think they don't have a folder for every url (I could be wrong) but it looks like they are using some type of rewriting. Has anyone had any success accomplishing such? |
||||||||||||
|
|
|||||||||||||
| Default Type |
|
comprug
Forum Regular
|
Jason,
I'm not sure if this exists on IIS, although it probably does. I know in Linux, you can set the default file type to ".cfm", so product => product.cfm. Otherwise, I believe it will revert to the file that's there if a .cfm file isn't found. By doing this on IIS, you can probably achieve the desired effect, but I don't know IIS. Or you could use Rails, and this would be really easy I didn't know Google discriminated against http://www.example.com/Product.cfm/Prod/11577857 .I thought it was only query parameters, but I might be wrong. As for HMS's urls, I believe they are folders, because I once got a virtual directory listing denied message. Another less efficient method would be to pipe all requests to a 404.cfm file, and have it analyze the cgi.script_name. |
||||||||||||
|
|
|||||||||||||
|
pmeserve
HostMySite Tech
|
The best way to do this is really with a framework like Rails and Apache + mod_rewrite(or app server like mongrel). All requests just pass into "routing" code within the app, and your own code decides how requests are parsed and processed. I mention Rails because it's what I use, but I'm fairly sure most of the popular frameworks these days support this
You may be able to hack up a solution with IIS & CF, but its going to be hard to do something like: routes.rb
URL: http://app.internal/calendar/show/2007/2/28 Using URLs in this intuitive, human-friendly way is very appealing. Tossing it all in as GET-variables is so 2004 |
||||||||||||||
|
|
|||||||||||||||
| Coldfusion |
|
comprug
Forum Regular
|
You mention that all routes should be centralized, and i've seen a couple sites use 404's to route requests in Coldfusion, but then again... |
|||||||||||||
|
|
||||||||||||||
|
Jason101
Forum Regular
|
As much as I would like to move to rails, my employer is 100% Windows and CF. We contract out everything that is not ColdFusion. (.Net Apps, etc) So I'm here 8 hours a day coding CF
Maybe sometime in my personal time I'll attempt rails. Anywho..thanks for the info on the URLS. Like Paul said, my ultimate goal is to get a url to look like: URL: http://app.internal/calendar/show/2007/2/28 And not have the URL params in it: URL: http://app.internal/calendar.cfm?action=show&year=2007&mon=2&day=28 I've read a few places about using some JRun connectors and/or IIS filters. But we all know that HMS won't let you run such a thing in the shared environments. So I'll keep hunting. |
||||||||||||
|
|
|||||||||||||
| Environments |
|
comprug
Forum Regular
|
Just curious, don't you have control over WaveWork's environments? Or is it a part-time gig. |
|||||||||||||
|
|
||||||||||||||
|
maryjos
|
Don't know if you've found a solution by now or not, since this is kind of an old thread. But you certainly can do this on CF as well...you just need to have something like mod-rewrite on the server. For Windows, most people use ISAPI_Rewrite. If you are in a shared environment and cannot use these, well there's really no way to replace the file name in the middle that I know of. If there is, I'd love to know about it!
|
||||||||||||
|
|
|||||||||||||
| Search Engine Safe URLs (SES) |
|
||
|


