Login or Sign Up
Logging in...
Remember me
Log in
Or
Sign Up
Forgot password or user name?
Log in with
Forums
Blogs
Articles
Groups
Galleries
Member List
Calendar
Home
Forum
Simply Business
Fucking Around & Business Discussion
Quick .htaccess question.. redirecting people.. help
Quick .htaccess question.. redirecting people.. help
Collapse
X
Collapse
Posts
Latest Activity
Photos
Page
of
1
Filter
Time
All Time
Today
Last Week
Last Month
Show
All
Discussions only
Photos only
Videos only
Links only
Polls only
Events only
Filtered by:
Clear All
new posts
Previous
template
Next
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#1
Quick .htaccess question.. redirecting people.. help
12-05-2005, 05:24 AM
Hey guys, i would like to redirect everyone that comes to
http://www.mysite.com
to
http://mysite.com
can i do that with .htaccess?
_________________
I am the best
woj
<&(©¿©)&>
Join Date:
Jul 2002
Posts:
47880
Share
Post
#2
12-05-2005, 05:28 AM
yes, I don't feel like writing it up though, heh
maybe someone else will do it, so here is a bump...
Custom Software Development, email: woj#at#wojfun#.#com to discuss details or skype: wojl2000 or gchat: wojfun or telegram: wojl2000
Affiliate program tools:
Hosted Galleries Manager
Banner Manager
Video Manager
Wordpress Affiliate Plugin
Pic/Movie of the Day
Fansign Generator
Zip Manager
Comment
Post
Cancel
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#3
12-05-2005, 05:34 AM
lol u suck
_________________
I am the best
Comment
Post
Cancel
ABC-Celebs
Confirmed User
Join Date:
Dec 2004
Posts:
285
Share
Post
#4
12-05-2005, 05:34 AM
Redirect index.html
http://mysite.com
Index.html should be your default first page.
Raffaele,
ABC-Celebs.com
Comment
Post
Cancel
fetishblog
Confirmed User
Join Date:
Sep 2005
Posts:
5995
Share
Post
#5
12-05-2005, 05:38 AM
Something like this might work.
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?yourdomain.com(/)?.*$ [NC]
RewriteRule .*$
http://yourdomain.com
[R,NC]
Fling.com
doesn't steal your traffic and sales unlike some other dating companies. I promote them, and so should you!
Comment
Post
Cancel
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#6
12-05-2005, 05:39 AM
that wont work..
bcuz IM TRYING TO redirect
http://www.mysite.com/index.html
to
http://mysite.com/index.html
wont work..
_________________
I am the best
Comment
Post
Cancel
ABC-Celebs
Confirmed User
Join Date:
Dec 2004
Posts:
285
Share
Post
#7
12-05-2005, 05:41 AM
Originally posted by
xxweekxx
that wont work..
bcuz IM TRYING TO redirect
http://www.mysite.com/index.html
to
http://mysite.com/index.html
wont work..
Have you tried
Redirect index.html
http://mysite.com/index.html
?
Raffaele,
ABC-Celebs.com
Comment
Post
Cancel
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#8
12-05-2005, 05:42 AM
Originally posted by
fetishblog
Something like this might work.
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?yourdomain.com(/)?.*$ [NC]
RewriteRule .*$
http://yourdomain.com
[R,NC]
didnt work
_________________
I am the best
Comment
Post
Cancel
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#9
12-05-2005, 05:43 AM
Originally posted by
ABC-Celebs
Have you tried
Redirect index.html
http://mysite.com/index.html
?
didnt work just made it go crazy, dont forget the index.html in
www.mysite.com
is the same index.html on mysite.com/index.hml
so it just kept refreshing from one to other non stop
_________________
I am the best
Comment
Post
Cancel
Scotty.T
Confirmed User
Join Date:
Nov 2004
Posts:
1062
Share
Post
#10
12-05-2005, 05:44 AM
RewriteCond %{HTTP_HOST} ^yourdomain.com$
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L]
Works for me.
Sorry. Just realised it was the other way you want to go. Not sure of the exact syntax for that.
Last edited by
Scotty.T
;
12-05-2005, 05:45 AM
.
.
Comment
Post
Cancel
Tempest
Too lazy to set a custom title
Join Date:
May 2004
Posts:
10217
Share
Post
#11
12-05-2005, 05:47 AM
Usually people want to do it the other way around... Got code to do that, but not what you're asking for..
Comment
Post
Cancel
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#12
12-05-2005, 05:47 AM
hmmwont work for me
_________________
I am the best
Comment
Post
Cancel
mkx
Confirmed User
Join Date:
Nov 2003
Posts:
4001
Share
Post
#13
12-05-2005, 05:49 AM
i think it is your dns configuration from your domain name registrar. Make sure that * is going to the same as www, hard to explain off hand, what registar are you using?
Comment
Post
Cancel
mkx
Confirmed User
Join Date:
Nov 2003
Posts:
4001
Share
Post
#14
12-05-2005, 05:50 AM
oh nevermind, thought it was the other way around
Comment
Post
Cancel
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#15
12-05-2005, 05:52 AM
yea,
what im trying to do is foward everyone that hits
http://www.mysite.com
to
http://mysite.com
wow nobody knows this on gfy?
_________________
I am the best
Comment
Post
Cancel
ABC-Celebs
Confirmed User
Join Date:
Dec 2004
Posts:
285
Share
Post
#16
12-05-2005, 05:53 AM
mmm...so strange!
Try
RewriteEngine on
RewriteCond %{HTTP_HOST} ^
www.mydomain.com
[NC]
RewriteRule ^(.*)$ http://mydomain.com/$1 [L,R=301]
Raffaele,
ABC-Celebs.com
Comment
Post
Cancel
xxweekxx
Confirmed User
Join Date:
Oct 2002
Posts:
6780
Share
Post
#17
12-05-2005, 05:55 AM
that worked! thanks man
_________________
I am the best
Comment
Post
Cancel
ABC-Celebs
Confirmed User
Join Date:
Dec 2004
Posts:
285
Share
Post
#18
12-05-2005, 05:56 AM
Originally posted by
xxweekxx
that worked! thanks man
np
Raffaele,
ABC-Celebs.com
Comment
Post
Cancel
Previous
template
Next
Working...
OK
OK
Cancel
😀
😂
🥰
😘
🤢
😎
😞
😡
👍
👎
☕
Comment