ich einen VPS-Server habe, und ich habe soeben eine neue Website, und ich den Befehl:Locke sagt, dass es 302 ist aber in .htaccess Ich habe 301
curl -I --resolve isvbscriptdead.com:80:IP_ADDRESS_HERE http://isvbscriptdead.com
HTTP/1.1 302 Found
Date: Wed, 22 Jun 2016 09:41:28 GMT
Server: Apache/2.4.7 (Ubuntu)
Location: https://isvbscriptdead.com/
Content-Type: text/html; charset=iso-8859-1
es Warum ist eine 302-Umleitung? Ich habe eine .htaccess hinzugefügt, dass alle Nicht-www HTTPS HTTPS umleitet:
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteCond %{ENV:HTTPS} off
RewriteRule^https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301,NE]
RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]
RewriteRule^https://%1%{REQUEST_URI} [L,R=301,NE]
RewriteEngine On
RewriteBase/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^/?(.*)$ /index.php?id=$1 [L]
RewriteCond %{HTTP_HOST} !^isvbscriptdead.com$ [NC]
RewriteRule ^(.*)$ http://isvbscriptdead.com/$1 [L,R=301]
Warum ist curl Berichterstattung ein 302?
Dies ist eher ein Apache-Konfigurationsproblem. curl zeigt Ihnen nur, was Ihr Apache-Server auf die HTTP-Anfrage reagiert ... –
also, wie kann ich Apache2 so konfigurieren, dass 301 statt 302 vorhanden ist? –
Haben Sie den Server neu gestartet? – hjpotter92