Register   Login
     
  Latest Posts  
RE: Featured articles: what's mean exactly?
by smcculloch on 11/20/2008 1:18 PM
RE: Module allows inappropriate directory listing
by smcculloch on 11/20/2008 1:16 PM
RE: One latest for a few categories
by smcculloch on 11/20/2008 1:06 PM
RE: Start on Listing Screen
by smcculloch on 11/20/2008 1:06 PM
RE: Need a tutorial and simple sample to develop token-based module
by smcculloch on 11/20/2008 1:04 PM
RE: Prevew of Custom rich text field?
by smcculloch on 11/20/2008 1:02 PM
Add existing module through current module
by kosmashang on 11/20/2008 12:42 PM
Prevew of Custom rich text field?
by Christian on 11/20/2008 12:08 PM
RE: Ratings button appears to anonymous users
by WillJean on 11/20/2008 4:11 AM
Need a tutorial and simple sample to develop token-based module
by nmduc073 on 11/20/2008 3:53 AM
  Forums  
Subject: An enhancement idea
Prev Next
You are not authorized to post a reply.

Author Messages
RabidmaxUser is Offline
Registered Users
Nuke Active Member
Nuke Active Member
Posts:34

6/02/2007 11:06 AM  

Hi Scott, after a quick idea from Bonder in an email to me, I thought I might put this up and see what you thought about it.

My proposition is that we add a new section in the web.config which is a list of path=(something) variable=(somethingelse) pairs, which work like this:

When creating a link, we check to see if the path is in this list. If it is, we check to see if the variable is in the querystring. If that is also there, we use the variable as the page name.

So given a page /home/my-blogs, with a blogtitle of red-wine, our resulting link  would be /home/my-blogs/red-wine.aspx

When getting an incoming link, we do the opposite. Firstly, check if the full string is in the database as a tabpath. If it isn't, assume it's using this new functionality, and find the tabpath in the web.config, take what is between the last / and the .aspx and reverse it into a querystring variable...

So an incoming url of /home/my-blogs/red-wine.aspx we'd not find /home/my-blogs/red-wine in the tabpaths, but it would be in the web-config with 'blogtitle' as the variable name, so we'd know that the resulting url is 'tabpath'/tabidstuff/default.aspx?blogtitle=red-wine

Some caveats:

1. We could only have one variable per tabpath, so that we didn't have to try to figure out which was supposed to be the one that we're using at a given point...

2. The tabpaths in the web.config section for this would need to be 'leaf' tabs, most likely. If we had tabs below one of these configured ones, we might run into problems...

 

The advantages are pretty clear for this kind of URL I'm sure everyone can see, but I suppose that modules would have to be written with this sort of functionality in mind, as usually the things they would use on the querystring would be 'blogid', which doesn't really make for an overly nice url really: /home/my-blogs/12.aspx? Shrug.

Any thoughts?

Max

You are not authorized to post a reply.
Forums > Projects > Friendly Urls > An enhancement idea



ActiveForums 3.7