locked
Remove Unique identifier From URL RRS feed

  • Question

  • User-2074110531 posted

     Hi guys,

     I have just stumbled across a litte problem with my URL's.

    Generally i use int's as my unique identifiers throughout most of my applications. However today i have been given an application that uses GUID as the identifiers, while this is not a problem to handle and has some advantages in this particuar application is it possible to remove the GUID from the URL example: 

     http://www.mysite.com/SomeFolder/a-new-title-A92D27E2-6F42-4a44-8676-6D6A39A3F28E.aspx

    as you can see this is a ugly URL and for my ints it works great (http://www.mysite.com/SomeFolder/a-new-title-2.aspx)

    I am using ASP.NET 3.5
    SQL 2005

    Look forward to your replies.

     

    Monday, March 2, 2009 12:18 PM

All replies

  • Monday, March 2, 2009 3:14 PM
  • User-2074110531 posted

    Hi there,

    Thanks for your reply, while i appreciate this is a URL rewrite and i have successfully configured many websites with URL rewriting i have simply URL rewritten like i previously shown (http://www.mysite.com/SomeFolder/a-new-title-2.aspx) always passing the unique identifier, please correct me if i am wrong but the only way i see possible to achieve removing the unique identifier (GUID) from the URL is to either have another column in the DB with the link URL and then pass the url in my stored procedure rather than the UI.

    My above theory may be incorrect but alarm bells sound if i am not loading content by using the unique identifier.

    Any suggestions?

     

    Tuesday, March 3, 2009 3:55 AM
  • User-2074110531 posted
    Anyone?
    Thursday, March 5, 2009 2:09 PM
  • User1747761241 posted

    Yes, you'd probably need a database to do it. 

    Thursday, March 5, 2009 2:21 PM
  • User-2074110531 posted

     Thanks for the reply,

     Yes i appreciate that a database is required but do you agree i would no longer load by using the unique identifier and in fact user a different column i.e page name ? as i believe this could cause problems with duplicate entries etc ?!?

     Thanks again.

    Thursday, March 5, 2009 3:20 PM