Go to Post It's only messy if you allow it to be. - Jay H 237 [more]
Home
Go Back   Chief Delphi > Technical > IT / Communications
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 22-08-2009, 18:29
Tanner's Avatar
Tanner Tanner is offline
Registered User
FRC #1261 (Roblions)
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Suwanee, GA
Posts: 311
Tanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to beholdTanner is a splendid one to behold
mod_rewrite

Hi all,

I'm trying to get our teams website to redirect anything from the main domain to a subfolder including all directories. For example:

prhsrobotics.com/ => prhsrobotics.com/team
prhsrobotics.com/folderA => prhsrobotics.com/team/folderA

I know it has to do with Apache's mod_rewrite (though you'd think there'd be something in cPanel to do this, idk), but I am terrible at Apache and regular expression stuff.

I've had results from Google, but none seem to work.

Help?

Thanks
-Tanner
  #2   Spotlight this post!  
Unread 22-08-2009, 23:58
lynca's Avatar
lynca lynca is offline
Andrew Lynch
FRC #2587 (DiscoBots)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2001
Location: Houston, TX
Posts: 1,612
lynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond reputelynca has a reputation beyond repute
Send a message via AIM to lynca
Re: mod_rewrite

Here are a few references on managing redirects in cPanel.

https://my.rochen.com/index.php?fuse...a rticleId=84

http://www.youtube.com/watch?v=heoD2HdOKqc
__________________
History: 624 - Cryptonite --> 118 - Robonauts --> 2158 - AusTIN CANS --> 2587 DiscoBots
Bio: Andrew Lynch "How I Work" ---- LinkedIn , Facebook, Twitter
  #3   Spotlight this post!  
Unread 23-08-2009, 12:25
Flyin' Axe's Avatar
Flyin' Axe Flyin' Axe is offline
Registered User
FRC #0188 (Woburn Robotics)
Team Role: Webmaster
 
Join Date: Mar 2009
Rookie Year: 2008
Location: Toronto, ON
Posts: 14
Flyin' Axe is an unknown quantity at this point
Send a message via MSN to Flyin' Axe
Re: mod_rewrite

Alternatively, you can try using

<?php Header("Location:http://www.google.ca"); ?>

This has to be a part of a php file. It probably wouldn't work for .html but I haven't tried it.

For HTML, you can use

<meta http-equiv="refresh" content="0; URL=http://www.google.ca">


Good Luck!
__________________

.

Last edited by Flyin' Axe : 23-08-2009 at 12:26. Reason: changing the value of content to instantly redirect
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 06:53.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi