A una web que tengo colgada en internet le quiero poner los menus en enlaces en formato php y llamarlos con un require, y poner todas las secciones de la web en carpetas para tenerlo todo ordenado y a la hora de actualizar la web no liarla parda y ahorrarme jaleo.
Lo raro es que los enlaces al las hojas de estilo (css) primeramente no me los pilla aun habiendole cambiado la ruta, las imagenes tampoco, y en cuanto les meto el require con el menu me sale esto al entrar en algun enlace:
Warning: require(menu/menui.php) [function.require]: failed to open stream: No such file or directory in C:\AppServ\www\sich2\ed1\edI.php on line 142
Fatal error: require() [function.require]: Failed opening required 'menu/menui.php' (include_path='.;C:\php5\pear') in C:\AppServ\www\sich2\ed1\edI.php on line 142
¿Que pasa o que estoy haciendo mal?
Gracias de antemano os poseteo los codigos
idex:
Código PHP:
<html>
<head>
<!--Prueba superada-->
<title>SALON INTERNACIONAL DEL COMIC DE HUELVA 2.0</title>
<script language="Javascript">
var BrowserDetect = {
init: function () {
this.browser = this.searchString(this.dataBrowser) || "An unknown browser";
this.version = this.searchVersion(navigator.userAgent)
|| this.searchVersion(navigator.appVersion)
|| "an unknown version";
this.OS = this.searchString(this.dataOS) || "an unknown OS";
},
searchString: function (data) {
for (var i=0;i<data.length;i++) {
var dataString = data[i].string;
var dataProp = data[i].prop;
this.versionSearchString = data[i].versionSearch || data[i].identity;
if (dataString) {
if (dataString.indexOf(data[i].subString) != -1)
return data[i].identity;
}
else if (dataProp)
return data[i].identity;
}
},
searchVersion: function (dataString) {
var index = dataString.indexOf(this.versionSearchString);
if (index == -1) return;
return parseFloat(dataString.substring(index+this.versionSearchString.length+1));
},
dataBrowser: [
{ string: navigator.userAgent,
subString: "OmniWeb",
versionSearch: "OmniWeb/",
identity: "OmniWeb"
},
{
string: navigator.vendor,
subString: "Apple",
identity: "Safari"
},
{
prop: window.opera,
identity: "Opera"
},
{
string: navigator.vendor,
subString: "iCab",
identity: "iCab"
},
{
string: navigator.vendor,
subString: "KDE",
identity: "Konqueror"
},
{
string: navigator.userAgent,
subString: "Firefox",
identity: "Firefox"
},
{
string: navigator.vendor,
subString: "Camino",
identity: "Camino"
},
{ // for newer Netscapes (6+)
string: navigator.userAgent,
subString: "Netscape",
identity: "Netscape"
},
{
string: navigator.userAgent,
subString: "MSIE",
identity: "Explorer",
versionSearch: "MSIE"
},
{
string: navigator.userAgent,
subString: "Gecko",
identity: "Mozilla",
versionSearch: "rv"
},
{ // for older Netscapes (4-)
string: navigator.userAgent,
subString: "Mozilla",
identity: "Netscape",
versionSearch: "Mozilla"
}
],
dataOS : [
{
string: navigator.platform,
subString: "Win",
identity: "Windows"
},
{
string: navigator.platform,
subString: "Mac",
identity: "Mac"
},
{
string: navigator.platform,
subString: "Linux",
identity: "Linux"
}
]
};
BrowserDetect.init();
if (BrowserDetect.browser == "Firefox") {
document.write("<LINK REL='stylesheet' HREF='estilos/style md v.css'>");
}
else {
if (BrowserDetect.browser == "Explorer"){
if (BrowserDetect.version>=7){
document.write("<LINK REL='stylesheet' HREF='estilos/style ie v.css'>");
}else{
document.write("<LINK REL='stylesheet' HREF='estilos/style ie v.css'>");
}
}else{
if (BrowserDetect.browser == "Opera"){
if (BrowserDetect.version<9){
document.write("<LINK REL='stylesheet' HREF='estilos/style ie v.css'>");
}else{
document.write("<LINK REL='stylesheet' HREF='estilos/style ie v.css'>");
}
}else{
document.write("<LINK REL='stylesheet' HREF='estilos/style v.css'>");
}
}
}
</script></head>
<body>
<ul class="navbar">
<?php
require ('menu/menui.php');
?>
</ul>
<ul class="navbar2">
<?php
require ('menu/menud5.php');
?>
</ul>
<div id="cabecera"><a href="index.html"><img src="img/LOGO V SICH copia.gif" width="466" height="130" border=0></a></img></div>
<div id="contenido">
<img src="img/SICH V Generico web.gif" width=340 height=400>
</div>
</body>
</html>
Código PHP:
<li><a href="ed5/edV.php"><img src="img/ed5.png" width=90 height=18 border=0></a>
<li><a href="ed4/edIV.php"><img src="img/ed4.png" width=90 height=18 border=0></a>
<li><a href="ed3/edIII.php"><img src="img/ed3.png" width=90 height=18 border=0></a>
<li><a href="ed2/edII.php"><img src="img/ed2.png" width=90 height=18 border=0></a>
<li><a href="ed1/edI.php"><img src="img/ed1.png" width=90 height=18 border=0></a>
<li><a href="fijas/contacto.php"><img src="img/contacto.png" width=90 height=18 border=0></a>
<li><a href="actividades.php"><img src="img/actrel.png" width=90 height=18 border=0></a>