Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Url Rewriting for dynamic urls

Posted on 2014-01-31
1
Medium Priority
?
289 Views
Last Modified: 2014-02-03
In my application, I want to rewrite Urls. Few of them are static and few of them are dynamic.The application is in asp.net 2.0. I have gone through few examples which are helped me to rewrite the static URL. but we are unable to rewrite urls which we populating through database. Below is the scenario.
Lets say, on main product page, I want to show list of sub products.This list we are binding through database with where it should redirect to. Now this suproduct is redirecting to its details page. http://www.something.com/subproductdetails.aspx?subproductid=1
I want to rewrite this URl with http://www.something.com/subproductName.
Is there any solution for the same, because without changing database value.
Thank You!
0
Comment
Question by:vikasbapat
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 16

Accepted Solution

by:
Easwaran Paramasivam earned 1500 total points
ID: 39825971
You have to write custom method in the  Application_BeginRequest event of global.ascx or you have to write custom module for it and provide  in the web.config file appropriately.


For more reference please do refer:

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

There is one more option.. save the original url and respective rewrite url in the DB or Dictionary and read and show accordingly. If you use DB in the sense have in Cache object for performance gain.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lots of people ask this question on how to extend the “MembershipProvider” to make use of custom authentication like using existing database or make use of some other way of authentication. Many blogs show you how to extend the membership provider c…
Sometimes in DotNetNuke module development you want to swap controls within the same module definition.  In doing this DNN (somewhat annoyingly) swaps the Skin and Container definitions to the default admin selections.  To get around this you need t…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…

596 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question