Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
Common Questions
 Helicon Tech : Common Questions
Subject Topic: ASP dynamic URL rewrite Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
forum99
Newbie
Newbie


Joined: 06 June 2008
Location: United Kingdom
Online Status: Offline
Posts: 7
Posted: 08 June 2008 at 8:46am | IP Logged Quote forum99

Hi, Im new to this rewrite method.

I have a asp website with dynamic URLs.
Kindly let me know how can I rewrite then as static.


Back to Top View forum99's Profile Search for other posts by forum99
 
Anton
Moderator Group
Moderator Group


Joined: 30 January 2007
Location: Ukraine
Online Status: Offline
Posts: 4695
Posted: 09 June 2008 at 8:32am | IP Logged Quote Anton

Please see examples here: http://www.helicontech.com/isapi_rewrite/doc/examples.htm

__________________
Regards,
Anton
Back to Top View Anton's Profile Search for other posts by Anton
 
forum99
Newbie
Newbie


Joined: 06 June 2008
Location: United Kingdom
Online Status: Offline
Posts: 7
Posted: 10 June 2008 at 4:09am | IP Logged Quote forum99

sorry I dont understand.

Kindly do it ..
http://www.mysite.com/view_colleges.php?c_id=1

I want it to http://www.mysite.com/university-of-wolverhampton/
OR
http://www.mysite.com/university-of-wolverhampton.php

Please help me.

Back to Top View forum99's Profile Search for other posts by forum99
 
Anton
Moderator Group
Moderator Group


Joined: 30 January 2007
Location: Ukraine
Online Status: Offline
Posts: 4695
Posted: 11 June 2008 at 5:09am | IP Logged Quote Anton

The rule should be:

RewriteBase /
RewriteRule ^university-of-wolverhampton/?$ view_colleges.php?c_id=1 [NC,L]

__________________
Regards,
Anton
Back to Top View Anton's Profile Search for other posts by Anton
 
forum99
Newbie
Newbie


Joined: 06 June 2008
Location: United Kingdom
Online Status: Offline
Posts: 7
Posted: 11 June 2008 at 7:44am | IP Logged Quote forum99

Ok .

RewriteBase /
RewriteRule ^university-of-wolverhampton/?$ view_colleges.php?c_id=1 [NC,L]

Where should I add this code in order to get the final result?
Back to Top View forum99's Profile Search for other posts by forum99
 
Sergey
Moderator Group
Moderator Group


Joined: 11 March 2005
Online Status: Offline
Posts: 712
Posted: 19 June 2008 at 9:13am | IP Logged Quote Sergey

Put this rule in "C:\Program Files\Helicon\ISAPI_Rewrite3\httpd.conf" or .htaccess file in the root site directory .
You can use HeliconManager or any other text editor.
Back to Top View Sergey's Profile Search for other posts by Sergey
 
forum99
Newbie
Newbie


Joined: 06 June 2008
Location: United Kingdom
Online Status: Offline
Posts: 7
Posted: 20 June 2008 at 12:17am | IP Logged Quote forum99

Thanks Sergey,

I have 5 dynamic url like this. You said the above rule need to be created and uploaded into root directory.

The above rule is for one URL. Should I created rule for other URLs ?
And should I  include all rules into one htaccess file??

Every time I need to write RewriteBase / or it's one time?

Is t require to put RewriteEngine On  ?

Kindly let me know
Back to Top View forum99's Profile Search for other posts by forum99
 
forum99
Newbie
Newbie


Joined: 06 June 2008
Location: United Kingdom
Online Status: Offline
Posts: 7
Posted: 20 June 2008 at 12:25am | IP Logged Quote forum99

One more thing I would like to add. Is the above rule you have suggested for PHP website? Because this is a Apache Based PHP website.


Back to Top View forum99's Profile Search for other posts by forum99
 
Sergey
Moderator Group
Moderator Group


Joined: 11 March 2005
Online Status: Offline
Posts: 712
Posted: 20 June 2008 at 4:50am | IP Logged Quote Sergey

#.htaccess

RewriteEngine On
RewriteBase /

RewriteRule ^university-of-wolverhampton/?$ view_colleges.php?c_id=1 [NC,L]
RewriteRule ...
RewriteRule ...
RewriteRule ...
RewriteRule ...
Back to Top View Sergey's Profile Search for other posts by Sergey
 
forum99
Newbie
Newbie


Joined: 06 June 2008
Location: United Kingdom
Online Status: Offline
Posts: 7
Posted: 24 June 2008 at 3:46am | IP Logged Quote forum99

OK. Thanks  Sergey,

Now I should create a .htaccess file using above code and upload into root directory , in order to rewrite all 5 dynamic URLs ??


Back to Top View forum99's Profile Search for other posts by forum99
 
Anton
Moderator Group
Moderator Group


Joined: 30 January 2007
Location: Ukraine
Online Status: Offline
Posts: 4695
Posted: 27 June 2008 at 7:43am | IP Logged Quote Anton

Can you please clarify your requirements in the last post.

__________________
Regards,
Anton
Back to Top View Anton's Profile Search for other posts by Anton
 
forum99
Newbie
Newbie


Joined: 06 June 2008
Location: United Kingdom
Online Status: Offline
Posts: 7
Posted: 30 June 2008 at 1:11am | IP Logged Quote forum99

Actually I want rewrite my web page url.

So I wanted to be confirmed that the example given by Sergey above is the final one to create a htaccess an upload into root directory ?



Back to Top View forum99's Profile Search for other posts by forum99
 
Anton
Moderator Group
Moderator Group


Joined: 30 January 2007
Location: Ukraine
Online Status: Offline
Posts: 4695
Posted: 01 July 2008 at 3:45am | IP Logged Quote Anton

You mentioned that you have 5 dynamic urls. but you have provided only one specific example. The rule for that example was provided by Sergey.
The rules for the rest of the urls should be written in a similar way.
If you provide specific examples of what you want to rewrite and how, we will create rules for you.


__________________
Regards,
Anton
Back to Top View Anton's Profile Search for other posts by Anton
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  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