This forum has been moved here:
Helicon Tech Community Forum

  Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
Common Questions
 Helicon Tech : Common Questions
Subject Topic: url rewite problem (Topic Closed Topic Closed) Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
Pushpender
Newbie
Newbie


Joined: 27 July 2009
Online Status: Offline
Posts: 2
Posted: 27 July 2009 at 3:47am | IP Logged  

Hi All,

I am having an e commerce website www.oflowers.in. I have
done url rewriting for product page whose url is like http://www.oflowers.in/Raksha-Bandhan/2/7/raksha-bandhan-
gifts.htm .Now my url has changed to another url.So how to
write new url for already written url in http.ini file.

Help from anybody would be hugely appreciated.
Thanks
Back to Top View Pushpender's Profile Search for other posts by Pushpender
 
Dima
Senior Member
Senior Member


Joined: 27 May 2009
Online Status: Offline
Posts: 162
Posted: 27 July 2009 at 9:27am | IP Logged  

Please show us your rules. Also please give an example of your old and new urls. And please specify version and build of your ISAPI_Rewrite.

__________________
HeliconTech moderator group.
Back to Top View Dima's Profile Search for other posts by Dima
 
Pushpender
Newbie
Newbie


Joined: 27 July 2009
Online Status: Offline
Posts: 2
Posted: 28 July 2009 at 12:22am | IP Logged  

Hi Dima,

My old written url is http://www.oflowers.in/subcat-2-7/raksha-bandhan-gifts.htm and i want to my new url like this http://www.oflowers.in/Raksha-Bandhan/2/7/raksha-bandhan-
gifts.htm.

The rules which i have written for new url is:

RewriteRule /fnp/(.*)/(.*)/(.*)/(.*).htm /fnp/Product.aspx?ID=$2&subcatid=$3

But the problem is that both the old and new url's are working instead what i want is to redirect  the old url to the new url.

I have written the url for the above mentioned task as:

RewriteRule /fnp/SubCat-2-7/Raksha-Bandhan.htm http://localhost/fnp/Raksha-Bandhan/2/7/raksha-bandhan-gifts.htm [I,O,RP,L]

This is working fine on my local machine but when i am uploading it on the server it displays:

The page has been moved to http://www.oflowers.in/Raksha-Bandhan/2/7/raksha-bandhan-gifts.htm.

Please help.

Thanks

    

Back to Top View Pushpender's Profile Search for other posts by Pushpender
 
Dima
Senior Member
Senior Member


Joined: 27 May 2009
Online Status: Offline
Posts: 162
Posted: 30 July 2009 at 7:18am | IP Logged  

Please specify your version and build of ISAPI_Rewrite.
For v.3 please try to use these rules:

RewriteBase /
#rule for your new urls
RewriteRule ^fnp/[^/]+/(\d+)/(\d+)/.+\.htm$ fnp/Product.aspx?ID=$1&subcatid=$2 [NC,L]
#redirecting rule for your old url
RewriteRule ^fnp/.+-(\d+)-(\d+)/(.+\.htm)$ fnp/Raksha-Bandhan/$1/$2/$3 [NC,L,R=301]


For v.2 please try to use these rules:

[ISAPI_Rewrite]
#rule for your new urls
RewriteRule /fnp/[^/]+/(\d+)/(\d+)/.+\.htm /fnp/Product.aspx?ID=$1&subcatid=$2 [I,L]
#redirecting rule for your old url
RewriteRule /fnp/.+-(\d+)-(\d+)/(.+\.htm) /fnp/Raksha-Bandhan/$1/$2/$3 [I,RP]


__________________
HeliconTech moderator group.
Back to Top View Dima's Profile Search for other posts by Dima
 

Sorry, you can NOT post a reply.
This topic is closed.

  Post ReplyPost New Topic
Printable version Printable version

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