Page 1 of 1
Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-10 23:07
by lucideye
Hallo,
Wollte mal fragen, wie man am besten
http://domain.com/.*? auf
http://www.domain.com/$1 umleitet. Also so, wie auch hier im Forum.
Re: Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-10 23:18
by teddybear
Per PHP Script:
Code: Select all
<?php header ("Location: http://deinziel.tld/subdir"); exit; ?>
Waere das z.B. moeglich einfach als index.php speichern und in das Root dir von domain.tld legen.
Brummige Gruesse
Teddy
Re: Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-10 23:24
by lucideye
Hi,
Ist leider keine Lösung.
Ersteinmal laufen Aufrufe á la
http://domain.com/subdir/, etc. normalerweise nicht über /index.php, zweitens dachte ich da eher an etwas über .htaccess.
Trotzdem danke.
Re: Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-10 23:27
by teddybear
Hm- Verstehe ich richtig das z.B.
http://blablabla.de nur nach
http://www.blablabla.de weitergeleitet werden soll?
Re: Weiterleitung http://domain.com auf http://www.domain.co
Posted: 2003-10-10 23:38
by Joe User
Re: Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-10 23:39
by lucideye
Ja, aber nicht nur.
So wie auch hier im Forum, inklusive des gesamte Pfades.
Klick doch mal:
http://www.rootforum.org/forum/viewtopic.php?t=17850
wird weitergeleitet auf:
http://www.rootforum.org/forum/viewtopic.php?t=17850
Re: Weiterleitung http://domain.com auf http://www.domain.co
Posted: 2003-10-10 23:40
by lucideye
Joe User wrote:
mod_rewrite
Ich will ja nicht umschreiben, ich will einen 301-Redirect.
Re: Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-10 23:49
by wirsing
Geht auch mit mod_rewrite. [R]
Re: Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-11 00:27
by Joe User
bitte selbst anpassen:
Code: Select all
RewriteEngine On
RewriteCond %{REQUEST_URI} ^{.*}.html$
RewriteRule ^(.*).html$ /$1.xhtml [R=301,L]
Re: Weiterleitung http://domain.com auf http://www.domain.com
Posted: 2003-10-11 00:29
by lucideye
Joe User wrote:bitte selbst anpassen:
Code: Select all
RewriteEngine On
RewriteCond %{REQUEST_URI} ^{.*}.html$
RewriteRule ^(.*).html$ /$1.xhtml [R=301,L]
Jo, super. Danke.
Code: Select all
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1?%{QUERY_STRING} [R=permanent,L]