• Toll-free  888-665-8637
  • International  +1 717-220-0012
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

bilchee
#1 Posted : Monday, February 9, 2009 6:00:25 AM(UTC)
bilchee

Rank: Member

Joined: 1/15/2009(UTC)
Posts: 4

Hello,

i am working on BVC5 .

I want to Leave .aspx extension from my page Custom URL.

i.e existing--> www.example.com/firstexample.aspx
Required--> www.example.com/firstexample/

when i put this Custom url to custom page field then after saving it, it automatically removes last forward slash. and result is page crash.

Is it possible if yes then how.

Thanks.
Marcus
#2 Posted : Monday, February 9, 2009 9:01:14 AM(UTC)
Marcus

Rank: Member

Joined: 11/5/2003(UTC)
Posts: 1,786

In order to do this you have to change IIS settings to map all requests to ASP.NET. It can be done but there are potential performance issues. For example, if you map all file types to ASP.NET then your images will be served by the ASP.NET process which is significantly slower than the static file module.

An alternative would be to create a "404" page that is ASP.NET. When a path that doesn't exist is found, IIS will redirect to the 404 error page. But, if you have a custom page you can grab the requested page name and redirect to the correct one or just return a 404 error.

In any case, in .net 3.5 SP1 there is a new web routing module that will make this easier. Unfortunately, ASP.NET doesn't have great support for this in web forms yet.
Matt@9BallDesign
#3 Posted : Monday, February 9, 2009 9:26:39 AM(UTC)
Matt@9BallDesign

Rank: Member

Joined: 12/23/2003(UTC)
Posts: 909

Hey marcus, if you're planning on opening up the ability to do this (extensionless URLs) in future versions, please keep the option wide open for us to allow for extensions!

Pretty please, with a cherry on top and whatever your other favorite toppings are...LOL..

Not expressing my opinions on the concept of extension vs. no extension. Rather helping some of us preserve years and years and years of engine performance and web wide linking.
Matt Martell


http://www.9balldesign.com - Web, Print, Graphic


http://www.martellhardware.com/ - Decorative & Builder's Hardware

------------------------------------------------
Aaron
#4 Posted : Monday, February 9, 2009 12:43:53 PM(UTC)
Aaron

Rank: Administration

Joined: 4/2/2004(UTC)
Posts: 2,393
United States
Location: Hummelstown, PA

Thanks: 6 times
Was thanked: 163 time(s) in 158 post(s)
Another option is to use an ASAPI filter like ASAPI Rewrite. The bottom line, as Marcus said, is that in IIS 6 and ASP.NET 2.0 there really isn't a great way to do this.
Aaron Sherrick
BV Commerce
Toll-free 888-665-8637 - Int'l +1 717-220-0012
Marcus
#5 Posted : Monday, February 9, 2009 12:56:09 PM(UTC)
Marcus

Rank: Member

Joined: 11/5/2003(UTC)
Posts: 1,786

Matt,

Yep, backwards compatibility is something that I want to support. What do you think of a pre-configured 301 redirect for all older BV pages plus the ability to add your own mappings for 301 redirects?
Matt@9BallDesign
#6 Posted : Monday, February 9, 2009 1:08:19 PM(UTC)
Matt@9BallDesign

Rank: Member

Joined: 12/23/2003(UTC)
Posts: 909

Oh, you know my beef about 301's. I explained it at length in 2007 and was told I was a dummy...LOL...he made good points... imagine what the size of that table could be... :)

My ISAPI files are hundres of times the size of what they suggest as the max number of lines and it's only a matter of time before I break the camel's back.

I like everything you're suggesting as long as we have the easy ability to use extensions or not use extensions.

SEO is a selling point of your application. Eliminate one type of rewriting (extensions) and use the other (no extensions) and you've lost the supporters of the eliminated practice when it comes time to the purchase decision.



If you can cover both sides, you're letting the developer/merchant decide rather than "forcing" them to use one or the other. three cheers for Mayor Marcus!
Matt Martell


http://www.9balldesign.com - Web, Print, Graphic


http://www.martellhardware.com/ - Decorative & Builder's Hardware

------------------------------------------------
Aaron
#7 Posted : Monday, February 9, 2009 1:11:43 PM(UTC)
Aaron

Rank: Administration

Joined: 4/2/2004(UTC)
Posts: 2,393
United States
Location: Hummelstown, PA

Thanks: 6 times
Was thanked: 163 time(s) in 158 post(s)
Marcus,

That sounds good, but I don't think the new URL scheme should be forced on merchants, even if the redirects are automatically applied. I have a few specific thoughts on how URL's should be handled, so I posted them in the BV 6 forum here: http://forums.bvcommerce.com/default.aspx?f=101&m=61181
Aaron Sherrick
BV Commerce
Toll-free 888-665-8637 - Int'l +1 717-220-0012
xotj123
#8 Posted : Tuesday, May 19, 2009 12:12:22 PM(UTC)
xotj123

Rank: Member

Joined: 10/19/2005(UTC)
Posts: 53

Here is a simple example I found, we did something similiar for a different app:

http://www.blogfodder.co.uk/post/2009/03/Dynamically-301-Redirect-404-Page-Not-Found-In-ASPNET.aspx

TJ Havens
Aaron
#9 Posted : Tuesday, May 19, 2009 3:05:06 PM(UTC)
Aaron

Rank: Administration

Joined: 4/2/2004(UTC)
Posts: 2,393
United States
Location: Hummelstown, PA

Thanks: 6 times
Was thanked: 163 time(s) in 158 post(s)
TJ,

This example is for redirecting, not rewriting. We built a similar, though faster, version of what is described in this article. Also, the example that the author shows will only work if a .aspx URL is requested. You could build a rewriter that acts on a 404, but that's not a good idea from a performance standpoint.
Aaron Sherrick
BV Commerce
Toll-free 888-665-8637 - Int'l +1 717-220-0012
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

©2024 Develisys. All rights reserved.
  • Toll-free  888-665-8637
  • International  +1 717-220-0012