he conseguido montar el tema de las webs amigables, interesante!! y ahora quiero a ver si alguien me da su consejo.
tengo montado un sistema de noticias. tengo un listado de articulos, y al clcickar ver aticulo muestro el resultado (le paso el id).
tengo un codigo tal que asi:
Código:
y esto me pinta en pantalla:$tituloURL=str_replace (" ", "-", $_GET['titulo']); if (isset($_GET['idnoticia'])) { $nuevaurl = $_SERVER['PHP_SELF']."/".$_GET['idnoticia']."/".$tituloURL.".html"; header("Location: ".$nuevaurl); } else { $idnoticia = $var_array[1]; $titulo = $var_array[2]; }
dominio.com/noticia.php/2/DNDE-ENCONTRAR-EMPLEO.html
mi preguntas son:
no podria quitar la URL? es decir, no podria quedarme algo como:
dominio.com/noticias/DNDE-ENCONTRAR-EMPLEO.html
he intentado quitar el PHP_SELF pero entonces no me funciona:
$nuevaurl = "noticias/".$_GET['idnoticia']."/".$tituloURL.".html";ç
lo que no quiero que se vea es el noticia.php?id=1
saludos!!
ferranWEB