<?php
$jump301=1;//是否开启301跳转开关,1开 0关
if(substr($_SERVER['SERVER_NAME'],0,4)!='www.'&&$jump301){
header('HTTP/1.1 301 Moved Permanently');
header('Location:http://www.'.$_SERVER['SERVER_NAME']);
exit();
}
?>
<?php
$jump301=1;//是否开启301跳转开关,1开 0关
if(substr($_SERVER['SERVER_NAME'],0,4)!='www.'&&$jump301)}
?>