kikoo tout le monde.
voilà petit problème avec la variable base_url.
pour la variable site_url pas de problème, je l’ai donc mis au final dans mon template.
j’ai donc mis au début base_url dans mon template
<base href="[(base_url)]" />
le problème c’est que sous IE, plus aucune image et lien ne s’affiche.
Comme je test principalement avec Firefox, je n’ai pas tout de suite vu le problème, mais je n’ai donc pas de soucis avec Firefox et Opéra, les liens retournés sont correct.
exemple lien retourné avec IE :
http:///assets/images/newsSilinkIdea.png
alors qu’elle est la différence entre ces deux variables sachant que dans mon config.inc.php, il y a
// automatically assign base_path and base_url
if($base_path==""||$base_url=="") {
$a = explode("/manager",str_replace("\\","/",dirname($_SERVER["PHP_SELF"])));
if(count($a)>1) array_pop($a);
$url = implode("manager",$a); reset($a);
$a = explode("manager",str_replace("\\","/",dirname(__FILE__)));
if(count($a)>1) array_pop($a);
$pth = implode("manager",$a); unset($a);
$base_url = $url.(substr($url,-1)!="/"? "/":"");
$base_path = $pth.(substr($pth,-1)!="/" && substr($pth,-1)!="\\"? "/":"");
$site_url = (!isset($_SERVER['HTTPS']) || strtolower($_SERVER['HTTPS']) != 'on')? 'http://' : 'https://';
$site_url .= $_SERVER['HTTP_HOST'];
if($_SERVER['SERVER_PORT']!=80) $site_url = str_replace(':'.$_SERVER['SERVER_PORT'],'',$site_url); // remove port from HTTP_HOST
$site_url .= ($_SERVER['SERVER_PORT']==80 || isset($_SERVER['HTTPS']) || strtolower($_SERVER['HTTPS'])=='on')? '':':'.$_SERVER['SERVER_PORT'];
$site_url .= $base_url;
}