PHP - header location
Résolu/Fermé
Fetide68
Messages postés
737
Date d'inscription
dimanche 4 janvier 2009
Statut
Membre
Dernière intervention
14 avril 2023
-
19 juin 2009 à 17:38
Fetide68 Messages postés 737 Date d'inscription dimanche 4 janvier 2009 Statut Membre Dernière intervention 14 avril 2023 - 13 juil. 2009 à 15:46
Fetide68 Messages postés 737 Date d'inscription dimanche 4 janvier 2009 Statut Membre Dernière intervention 14 avril 2023 - 13 juil. 2009 à 15:46
A voir également:
- PHP - header location
- Easy php - Télécharger - Divers Web & Internet
- Gpt header corruption ✓ - Forum Windows 10
- Php?id=1 - Forum PHP
- \R php ✓ - Forum PHP
- Get_magic_quotes_gpc php 8 ✓ - Forum PHP
3 réponses
zoubiock
Messages postés
57
Date d'inscription
mardi 12 mai 2009
Statut
Membre
Dernière intervention
2 mars 2010
10
19 juin 2009 à 18:00
19 juin 2009 à 18:00
Pourquoi tu n'essaierais pas un truc comme ça plutôt:
<?php
$dns = 'www.commetcamarche.net';
if ($_SERVER['HTTP_HOST']==$dns)
{
break;
}
else
{
header ('location: http://'.$dns);
}
?>
<?php
$dns = 'www.commetcamarche.net';
if ($_SERVER['HTTP_HOST']==$dns)
{
break;
}
else
{
header ('location: http://'.$dns);
}
?>
Fetide68
Messages postés
737
Date d'inscription
dimanche 4 janvier 2009
Statut
Membre
Dernière intervention
14 avril 2023
32
19 juin 2009 à 18:43
19 juin 2009 à 18:43
Le problème persiste, mais c'est quoi cette fonction ?
Fetide68
Messages postés
737
Date d'inscription
dimanche 4 janvier 2009
Statut
Membre
Dernière intervention
14 avril 2023
32
13 juil. 2009 à 15:46
13 juil. 2009 à 15:46
Pour info, la solution est là (on parle d'urls canoniques...) :
http://www.commentcamarche.net/forum/affich 13190735 ajout auto des www dans l adresse
http://www.commentcamarche.net/forum/affich 13190735 ajout auto des www dans l adresse