Thanks,
for this we will have to make considerable changes in the code. The application is massive and we can only work with querystring eid.
Events will be entered to the system only once and each will have its own unique number (eID) therefore I need a solution such as "URL Mapping", or is there another way?
Any examples would be appreciated on .NET CSharp if applicable.
Many thanks
Main Topics
Browse All Topics





by: Hube02Posted on 2009-05-15 at 08:07:11ID: 24396519
Okay, first, let me say that I'm no expert with rewriting on IIS7 or C#, but my comments are more to the point of theory than actual coding.
* eid=2e051e 40-63d0-dd 11-a62a- 00 3048676ea7
t.com/conc erts-ticke ts/melanie - tickets *
t.com/thea tre-ticket s/oliver- t ickets/200 90515
It probably is not a good idea to try to generate a different unique rewrite rule for every posibility in the database, this is due to the fact that this list would have to be regenerated every time the is a database changes. Instead, I would look for a way to create several generic rewrites that would encompass all the possibilities.
So lets take a single example from your above examples:
**************************
The url structure:
www.domain.com/Music.aspx?
Should rewrite as
http://www.yourticketmarke
**************************
What I would do here is have a rule that rewrites:
/concerts-tickets/melanie
to:
/Music.aspx?artist=melanie
I'm just using artist=melanie for an example. This would also need to be something unique in your database.
Now, when Music.aspx is called, instead of looking up the eid value, you would look up the artist value to get the eid value and then process your page as normal. What this means is that you only need 3 rewrite rules rather than the potential thousands of rules you would need if you have a very large database of information.
What this means, as mentioned above, each event name would need to be unique in some way so that you can look up the event by the event name, rather than by the eid value. So a change to the way the database functions. In this case I might alter the rule a bit. For instance, each event may not have a unique name, but each event is likely associated with a specific date, so the event name combined with the event date would give you a unique combination that you can look up. This means that instead of the URLs you propose, you would also need to include the date somehow.
for instance:
http://www.yourticketmarke