I have been working on a site, and I am trying to make a simple database system for it. I know that there is MySQL, but I do not want to use that. The problem I am facing is pretty simple... This is the code...
So the problem that I am facing, I have "document.write(sn);" but I want to replace it with a script that mounts an external .js file. Basically, is there a JavaScript equivalent of... "<script type="text/javascript" src=""></script>"
I would appreciate ALL help. Thanks!
<html>
<head>
<script type="text/javascript">
function show_prompt()
{
var sn=prompt("Please enter the Serial Number","");
if (sn!=null && sn!="")
{
document.write(sn);
}
}
</script>
</head>
<body>
<input type="button" onclick="show_prompt()" value="Show prompt box" />
</body>
</html>
<head>
<script type="text/javascript">
function show_prompt()
{
var sn=prompt("Please enter the Serial Number","");
if (sn!=null && sn!="")
{
document.write(sn);
}
}
</script>
</head>
<body>
<input type="button" onclick="show_prompt()" value="Show prompt box" />
</body>
</html>
So the problem that I am facing, I have "document.write(sn);" but I want to replace it with a script that mounts an external .js file. Basically, is there a JavaScript equivalent of... "<script type="text/javascript" src=""></script>"
I would appreciate ALL help. Thanks!
Comment