Avatar of kruegerste
kruegersteFlag for United States of America asked on

Asp.Net 3.5 Url Rewriting Solution and C#

Hello,

Can someone please instruct me and also provide an example of the best way to "rewrite" urls to more seo/customer friendly urls using ASP.NET 3.5?

I see the in ASP.NET 1.0 and 2.0 that most had to use url rewriting modules or custom rewrite methods to achieve this.  Now 3.5 has this System.Web.Routing assembly included in it.  Is this new assembly the best way to go or is there a superior 3rd party module from 1.1 or 2.0 that would work better, even with 3.5?

If the answer is use System.Web.Routing assembly, could someone provide an example of how to convert the following url (I have found many references on web but none address the parameters in querystring)?

convert
 "~/games/game.aspx?gameid=12345&seasonid=2009"
 to
"~/games/2009/12345

We are not sure how to convert the parameters to this format or retrieve the much needed values after the page renders.

Thanks.

ASP.NETC#.NET Programming

Avatar of undefined
Last Comment
TheMozz

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
TheMozz

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
TheMozz

ASKER
kruegerste

Thanks for the quick reply.  But could you please answer the first and main part of our question?  I'm assuming I know your answer but want to make sure.  Are you saying that using the System.Web.Routing is the best solution as of today for asp.net 3.5 and url rewriting?  

If so, that first example is a good one and would probably do me well.

Thanks.
SOLUTION
TheMozz

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes