Hello, I have this problem with my .Asp file. I get an error saying 'GetFrontpageInfo' is undefined.
This is the code:
http://www.kollelbaaleibatim.com/Content_of_asp_file.txt
click "view source" to see the code.
TY
Hello, I have this problem with my .Asp file. I get an error saying 'GetFrontpageInfo' is undefined.
This is the code:
http://www.kollelbaaleibatim.com/Content_of_asp_file.txt
click "view source" to see the code.
TY
You are trying to call a server side function from client side code.
The onLoad
event is fired in the browser, so a client side function called GetFrontpageInfo
cannot be found.
Remove the attribute and place the following at the bottom of your page:
<% GetFrontpageInfo() %>
This way, you are calling server side code from the server side.
Update:
Looking at the code again - you are also trying to call in client side in the onClick event of your input button.
An additional problem is that you are trying to call alert on the server side. This is not possible.
Perhaps you should change your function from server side (enclosed in <%%>
) to client side script, and return the call to the onload
event in the body tag:
<script language="vbscript>
sub GetFrontpageInfo()
ShortTitleLeftCar = "temp value in variable"
messagebox(ShortTitleLeftCar)
end sub
</script>
You seem to be mixing VBScript and Javascript, as well as client side and server side code.
it looks like you function GetFrontpageInfo is defined as a server-side method, but you are calling it on the client side. <body onload="GetFrontpageInfo">
is looking for a Javascript function called GetFrontpageInfo