URL Rewrite

For general questions and discussions specific to the AbleCommerce 7.0 Asp.Net product.
Post Reply
vn2479
Ensign (ENS)
Ensign (ENS)
Posts: 20
Joined: Thu Jul 29, 2010 12:43 pm

URL Rewrite

Post by vn2479 » Tue Aug 17, 2010 12:20 pm

Hello,

I am running Window IIS 7 server 2008 and AC 7. Window IIS 7 has its own URL Rewrite Module, not sure what AC 7 has to offer . Which is better to use? Thanks!

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: URL Rewrite

Post by mazhar » Wed Aug 18, 2010 4:31 am

I don't know about IIS7 rewrite module but I would suggest to keep the one bundled with AbleCommerce out of the box.

User avatar
AbleMods
Master Yoda
Master Yoda
Posts: 5170
Joined: Wed Sep 26, 2007 5:47 am
Location: Fort Myers, Florida USA

Re: URL Rewrite

Post by AbleMods » Wed Aug 18, 2010 1:25 pm

mazhar wrote:but I would suggest to keep the one bundled with AbleCommerce out of the box.
What URL rewriter? We can modify how the URLs are built in AC7?
Joe Payne
AbleCommerce Custom Programming and Modules http://www.AbleMods.com/
AbleCommerce Hosting http://www.AbleModsHosting.com/
Precise Fishing and Hunting Time Tables http://www.Solunar.com

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: URL Rewrite

Post by jmestep » Thu Aug 19, 2010 7:04 am

I know a couple of merchants that tried using the rewrite in IIS7 to redirect from cfm pages to aspx pages, but it didn't work nearly as well as Helicon rewrite.
Also, Able has a rewrite provider in 7.0.3 on.
http://wiki.ablecommerce.com/index.php/ ... ovider_API
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

User avatar
AbleMods
Master Yoda
Master Yoda
Posts: 5170
Joined: Wed Sep 26, 2007 5:47 am
Location: Fort Myers, Florida USA

Re: URL Rewrite

Post by AbleMods » Thu Aug 19, 2010 8:32 am

Hey thanks Judy, I didn't know that was there.

Have you ever done the rewrite API like that Wiki before? Is it fairly straightforward?
Joe Payne
AbleCommerce Custom Programming and Modules http://www.AbleMods.com/
AbleCommerce Hosting http://www.AbleModsHosting.com/
Precise Fishing and Hunting Time Tables http://www.Solunar.com

vn2479
Ensign (ENS)
Ensign (ENS)
Posts: 20
Joined: Thu Jul 29, 2010 12:43 pm

Re: URL Rewrite

Post by vn2479 » Thu Aug 19, 2010 9:02 am

Thanks for heads up! I'll give AC7 URL Rewrite a try. Question. Are there any resources on here on how to write custom rewrite rules and 301 redirect on multiple pages? Thanks, again!

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: URL Rewrite

Post by jmestep » Fri Aug 20, 2010 7:12 am

Joe,
I haven't done it because I haven't had a compelling reason- in other word's, no one has wanted to pay for it and I've got too much to do to have time to experiment!
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: URL Rewrite

Post by mazhar » Sun Aug 22, 2010 11:44 pm

vn2479 wrote:Thanks for heads up! I'll give AC7 URL Rewrite a try. Question. Are there any resources on here on how to write custom rewrite rules and 301 redirect on multiple pages? Thanks, again!
Read following topic about rewrites
http://wiki.ablecommerce.com/index.php/ ... ovider_API

Read following topic about 301 redirects
http://wiki.ablecommerce.com/index.php/ ... leCommerce

User avatar
AbleMods
Master Yoda
Master Yoda
Posts: 5170
Joined: Wed Sep 26, 2007 5:47 am
Location: Fort Myers, Florida USA

Re: URL Rewrite

Post by AbleMods » Tue Aug 24, 2010 1:45 pm

Ok, I gave this a try but it's just not working for me ....

I added the reference to CommerceBuilder - no biggie.
I compiled the DefaultProvider.vb and the DLL goes into the /Bin/ folder as it should.
I restarted IIS each time after re-compiling.

I can see the store URL's now have -VB- in them, so I know the sample is re-working the URLs.

But I keep keeping page-not-found even with the smallest change to the code like this:

Code: Select all

                Case CatalogNodeType.Product
                    Return String.Format("~/{1}-VB-P{0}.aspx", nodeId, SanitizeName(name))
to:

Code: Select all

                Case CatalogNodeType.Product
                    Return String.Format("~/{1}-VB-P{0}-JOE.aspx", nodeId, SanitizeName(name))
The links build correctly - I can hover them and see the -JOE has been added. But clicking them just throws a page-not-found error.

What am I missing here?? This is in 7.0.5 by the way.....
Joe Payne
AbleCommerce Custom Programming and Modules http://www.AbleMods.com/
AbleCommerce Hosting http://www.AbleModsHosting.com/
Precise Fishing and Hunting Time Tables http://www.Solunar.com

Post Reply