Anonymous
public text v1 · immutable<?php
$url = split("[\.]", $_SERVER['SERVER_NAME']);
if(trim(strtolower($url[0])) == 'www') {
// DEMaS CoDIGO
echo 'p√°gina principal';
}else {
header("Location: http://www.".$_SERVER['SERVER_NAME']);
}
?>