Jan 9, 2013 at 10:06 PM
Edited Jan 9, 2013 at 10:12 PM
I've got a site up and running nicely with Orchard (migrating from an old site in php).
The problem I've got now is that there are a lot of pages indexed in google against the old php site (with the old domain name).
The plan is to switch the old domain over via DNS to the new domain name and the Orchard site.
An old link in google is similar to www.olddomain.com/products/all/make/condition/Partno.html
(Ideally I'd like this to go to a URL like www.newdomain.com/products/all/index.aspx?p=partno&m=make&c=condition)
In reality this maps to a php file called index in the products/all directory - this takes the parameters make, condition and part no to do its processing (it doesn't point to a physical file)
I need to replicate this functionality in the Orchard site (so any requests coming in will get taken to an appropriate page).
At present, as there nothing in place to handle this on the orchard site, so I'm just getting a this page cannot be found as the content of the orchard page.
What would be the best way for me to handle this?
I've thought of putting a web form into the all directory and then manipulating the request to get the parameters out (not 100% sure how to make the aspx become extension less though). I've tried this and it seems to work, other than not being able to remove
the aspx extension from the URL, which isn't much use for me at the moment (havn't got to the parameter part yet)
Another option I've thought of is to use the URL rewrite option in iis7, but not sure if this will give me what I want, yet alone know what rule to setup to do this.
Or, should I create a custom module called products, with a controller action of all to handle the request and get this to mimic the original php file?
Not sure which way to go with this. Anyone got any suggestions on he best route for me to try?