This forum has been moved here:
Helicon Tech Community Forum

  Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
Common Questions (Forum Locked Forum Locked)
 Helicon Tech : Common Questions
Subject Topic: ASP dynamic URL rewrite (Topic Closed Topic Closed)
Author
Message |
forum99
Newbie


Joined: 06 June 2008
Location: United Kingdom
Posts: 7
Posted: 08 June 2008 at 8:46am  

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
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 09 June 2008 at 8:32am  

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

__________________
Regards,
Anton
Back to Top
 
forum99
Newbie


Joined: 06 June 2008
Location: United Kingdom
Posts: 7
Posted: 10 June 2008 at 4:09am  

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
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 11 June 2008 at 5:09am  

The rule should be:

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

__________________
Regards,
Anton
Back to Top
 
forum99
Newbie


Joined: 06 June 2008
Location: United Kingdom
Posts: 7
Posted: 11 June 2008 at 7:44am  

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
 
Sergey
Admin Group


Joined: 11 March 2005
Posts: 750
Posted: 19 June 2008 at 9:13am  

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
 
forum99
Newbie


Joined: 06 June 2008
Location: United Kingdom
Posts: 7
Posted: 20 June 2008 at 12:17am  

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
 
forum99
Newbie


Joined: 06 June 2008
Location: United Kingdom
Posts: 7
Posted: 20 June 2008 at 12:25am  

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
 
Sergey
Admin Group


Joined: 11 March 2005
Posts: 750
Posted: 20 June 2008 at 4:50am  

#.htaccess

RewriteEngine On
RewriteBase /

RewriteRule ^university-of-wolverhampton/?$ view_colleges.php?c_id=1 [NC,L]
RewriteRule ...
RewriteRule ...
RewriteRule ...
RewriteRule ...
Back to Top
 
forum99
Newbie


Joined: 06 June 2008
Location: United Kingdom
Posts: 7
Posted: 24 June 2008 at 3:46am  

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
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 27 June 2008 at 7:43am  

Can you please clarify your requirements in the last post.

__________________
Regards,
Anton
Back to Top
 
forum99
Newbie


Joined: 06 June 2008
Location: United Kingdom
Posts: 7
Posted: 30 June 2008 at 1:11am  

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
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 01 July 2008 at 3:45am  

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
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version
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