URL rewrite

  • Thread starter Thread starter polilop
  • Start date Start date
Is there a URL rewrite module that allows to rewrite url by
looking at the database.
Egxample:http://www.somesite.com/object.aspx?objectCountryId=1&objectId=22
now i look into the database, see that objectCountryId =1 in the database is
"France"
and ObjectId=22 is "James mannor", and then rewrite so url looks likehttp://www.somesite.com/object.aspx/France/Jamesmannor/

I think you can find a lot

http://urlrewriter.net
http://www.urlrewriting.net
http://www.google.com/search?hl=en&q=url+rewrite+module

In general, such links can be easily maintained using the
Request.PathInfo property.

In Page_Load() you will need to get

string[] query = Request.PathInfo.Split('/');

where query[0] will be "France" and query[1]="James mannor"

More about this property
http://weblogs.asp.net/scottgu/archive/2007/02/26/tip-trick-url-rewriting-with-asp-net.aspx

Hope this helps.
 
Back
Top