seijas8819 de Enero del 2004
PreguntaHola, estoy intentando crear un archivo javascript aparte con una función para luego en mis páginas html poder hacer referencia a la función cuando quiera y no me funciona. He hecho lo siguiente:
el archivo javaScritp con la función es el siguiente:
function printVirtualFooter()
{
document.write("<hr width = "500">+<br>");
document.write("<a href = "company/index.html">company</a> |");
document.write("<a href = "portfolio/index.html">portfolio</a> |");
document.write("<a href = "jobs/index.html">jobs</a> |");
document.write("<a href = "contact/index.html">contact</a> |");
}
y luego en el archivo html hago lo siguiente:
<html>
<head>
<script languaje = "JavaScript" scr="footer.js">
</script>
</head>
<body>
<table width = "50%" height = "50%" align = "center" valign = "middle" border = "1">
<tr>
<td>
hola
</td>
</tr>
<tr>
<td height = "40">
</td>
</tr>
<tr>
<td>
<script languaje = "JavaScript">
printVirtualFooter();
</script>
</td>
</tr>
</table>
</body>
</html>
al ejecutar el archivo html no me saca nada de la función printVirtualFooter, o sea no me pone nada pero tampoco que haya un error.
Que he hecho mal?
Por favor contestarme
Gracias
el archivo javaScritp con la función es el siguiente:
function printVirtualFooter()
{
document.write("<hr width = "500">+<br>");
document.write("<a href = "company/index.html">company</a> |");
document.write("<a href = "portfolio/index.html">portfolio</a> |");
document.write("<a href = "jobs/index.html">jobs</a> |");
document.write("<a href = "contact/index.html">contact</a> |");
}
y luego en el archivo html hago lo siguiente:
<html>
<head>
<script languaje = "JavaScript" scr="footer.js">
</script>
</head>
<body>
<table width = "50%" height = "50%" align = "center" valign = "middle" border = "1">
<tr>
<td>
hola
</td>
</tr>
<tr>
<td height = "40">
</td>
</tr>
<tr>
<td>
<script languaje = "JavaScript">
printVirtualFooter();
</script>
</td>
</tr>
</table>
</body>
</html>
al ejecutar el archivo html no me saca nada de la función printVirtualFooter, o sea no me pone nada pero tampoco que haya un error.
Que he hecho mal?
Por favor contestarme
Gracias
