I have implemented the .NET Login functionality, and I am receiving a JavaScript Error whenever a User clicks on the Log-In Anchor Button to reach the Login.aspx.
This Anchor Menu Button is part of the CSS Menu which is defined within the Master Page.
When I run this locally, the error indicates:
‘ddmegamenu’ is undefined
However this script is defined within the MasterPage:
All of the sub-pages can see this script including the Login.aspx:
<script type="text/javascript">
ddmegamenu.docinit({
menuid: 'solidmenu',
dur: 200 //<--no comma after last setting
})
</script>
Here is the development site: http://www.virtualpetstore.com
The Login.aspx is within a seperate Account Directory, but I don’t think this should be a problem.
If anyone can see this issue, I would really appreciate it.
You’re getting the error because you’re not properly referencing the JS files on the Login.aspx page. This is what the console says (in addition to the error that you posted):
Ensure that your JS files are being loaded and your error will most likely disappear.
Hint: Your script tags should look something like this: