Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:43
.asp script error with menu
Poster: winbach
Dated: Thursday May 26 2005 - 16:29:20 BST
Greetings. I am getting this error
Active Server Pages error 'ASP 0138'
Nested Script Block
/quote/callusband.asp, line 40
A script block cannot be placed inside another script block.
Line 40 is the Milonic menu so am a bit confused.
My file link is
http://www.quakeinsurance.net/quote/callusband.asp
Include file in file link is:
http://www.quakeinsurance.net/quote/callusbandFORM.asp
HELP! I am totally stuck.
Thanks for your time.
Poster: John
Dated: Thursday May 26 2005 - 16:53:32 BST
I'm getting just a hair different...
Code:
Active Server Pages error 'ASP 0138'
Nested Script Block
/quote/callusband.asp, line 39
A script block cannot be placed inside another script block.
Nested Script Block
/quote/callusband.asp, line 39
A script block cannot be placed inside another script block.
Without actually seeing it things are a bit tough, but offhand it sounds like a coding error.
Post your code here. Don't forget to use the code tags when doing so.
Poster: winbach
Dated: Thursday May 26 2005 - 18:13:12 BST
Here is the code.. thanks so much for your assistance.
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<!-- TemplateBeginEditable name="doctitle" -->
<title>California Earthquake Residential Insurance</title>
<!-- TemplateEndEditable --><style type="text/css">
<!--
body {
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
background-color: #003366;
}
body,td,th {
font-family: Arial, Helvetica, sans-serif;
font-size: 10px;
}
-->
</style>
<link href="../quake.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style8 {font-size: 12px}
.style10 {color: #FFFFFF}
-->
</style>
<!-- TemplateBeginEditable name="head" --><!-- TemplateEndEditable -->
</head>
<body>
<script type="text/javascript" src="../milonic_src.js"></script>
<script type="text/javascript">
<!--
if(ns4)_d.write("<script language=JavaScript src=mmenuns4.js><\/script>");
else _d.write("<script language=JavaScript src=mmenudom.js><\/script>");
-->
</script>
<script type="text/javascript" src="../menu_data.js"></script>
<br>
<a href="../index.htm"> </a><!-- #BeginLibraryItem "/Library/QuoteTopNav.lbi" -->
<link href="../quake.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style1 {color: #333333}
.style2 {color: #CC0000}
-->
</style>
<table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td height="63" valign="top" background="../Library/images/lines.gif"><div align="left"><img src="../images/quakelogotopnav.gif" width="165" height="50" border="0" align="left" usemap="#Map">
<table width="568" height="68" border="0" align="left" cellpadding="0" cellspacing="0" background="../images/6lines.gif">
<tr valign="bottom" class="topnav">
<td width="106" height="41"><p class="topnav"><strong> </strong></p></td>
<td width="109" class="topnav"> <strong><a href="../Commercial_quote.htm">Commercial<br>
Instant Quote</a></strong></td>
<td width="91" class="topnav"><a href="../residential.htm"> Residential</a></td>
<td width="88" class="topnav"> <a href="../commercial.htm">Commercial</a></td>
<td width="83" class="topnav"><a href="../about.htm">About Us </a></td>
<td width="91" class="topnav"><a href="../contact.htm">Contact Us </a></td>
</tr>
<tr class="topnav">
<td height="27" valign="middle"><strong> <a href="quickquote.asp" class="TopNavItems style2"><span class="style2">Residential</span><br>
<span class="style2">Instant Quote</span></a> </strong></td>
<td valign="middle" class="topnav"> </td>
<td valign="middle" class="topnav"> </td>
<td valign="middle" class="topnav"> </td>
<td valign="bottom" class="TopNavItems"> </td>
<td valign="middle" class="topnav"> </td>
</tr>
</table>
</div></td>
</tr>
<tr>
<td height="29" valign="top" background="../Library/images/lines.gif"><hr noshade>
</td>
</tr>
</table>
<map name="Map">
<area shape="rect" coords="1,5,163,45" href="../index.htm">
</map>
<!-- #EndLibraryItem --><br>
<table width="100%" height="188" border="0" cellpadding="10" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td valign="top">
<div align="center"><!--#include file="../quotes/callusbandFORM.asp" --></div></td>
</tr>
</table>
<br>
<!-- #BeginLibraryItem "/Library/bottomcopyright.lbi" --><!-- #BeginLibraryItem "/Library/bottomcopyright.lbi" -->
<table width="100%" height="33" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td bgcolor="#666666" class="small"> </td>
</tr>
<tr>
<td height="19" class="small"><div align="center">©2005 Tegner-Miller Insurance Brokers CA License #0466134 </div></td>
</tr>
</table>
<!-- #EndLibraryItem --><!-- #EndLibraryItem -->
</body>
</html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<!-- TemplateBeginEditable name="doctitle" -->
<title>California Earthquake Residential Insurance</title>
<!-- TemplateEndEditable --><style type="text/css">
<!--
body {
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
background-color: #003366;
}
body,td,th {
font-family: Arial, Helvetica, sans-serif;
font-size: 10px;
}
-->
</style>
<link href="../quake.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style8 {font-size: 12px}
.style10 {color: #FFFFFF}
-->
</style>
<!-- TemplateBeginEditable name="head" --><!-- TemplateEndEditable -->
</head>
<body>
<script type="text/javascript" src="../milonic_src.js"></script>
<script type="text/javascript">
<!--
if(ns4)_d.write("<script language=JavaScript src=mmenuns4.js><\/script>");
else _d.write("<script language=JavaScript src=mmenudom.js><\/script>");
-->
</script>
<script type="text/javascript" src="../menu_data.js"></script>
<br>
<a href="../index.htm"> </a><!-- #BeginLibraryItem "/Library/QuoteTopNav.lbi" -->
<link href="../quake.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style1 {color: #333333}
.style2 {color: #CC0000}
-->
</style>
<table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td height="63" valign="top" background="../Library/images/lines.gif"><div align="left"><img src="../images/quakelogotopnav.gif" width="165" height="50" border="0" align="left" usemap="#Map">
<table width="568" height="68" border="0" align="left" cellpadding="0" cellspacing="0" background="../images/6lines.gif">
<tr valign="bottom" class="topnav">
<td width="106" height="41"><p class="topnav"><strong> </strong></p></td>
<td width="109" class="topnav"> <strong><a href="../Commercial_quote.htm">Commercial<br>
Instant Quote</a></strong></td>
<td width="91" class="topnav"><a href="../residential.htm"> Residential</a></td>
<td width="88" class="topnav"> <a href="../commercial.htm">Commercial</a></td>
<td width="83" class="topnav"><a href="../about.htm">About Us </a></td>
<td width="91" class="topnav"><a href="../contact.htm">Contact Us </a></td>
</tr>
<tr class="topnav">
<td height="27" valign="middle"><strong> <a href="quickquote.asp" class="TopNavItems style2"><span class="style2">Residential</span><br>
<span class="style2">Instant Quote</span></a> </strong></td>
<td valign="middle" class="topnav"> </td>
<td valign="middle" class="topnav"> </td>
<td valign="middle" class="topnav"> </td>
<td valign="bottom" class="TopNavItems"> </td>
<td valign="middle" class="topnav"> </td>
</tr>
</table>
</div></td>
</tr>
<tr>
<td height="29" valign="top" background="../Library/images/lines.gif"><hr noshade>
</td>
</tr>
</table>
<map name="Map">
<area shape="rect" coords="1,5,163,45" href="../index.htm">
</map>
<!-- #EndLibraryItem --><br>
<table width="100%" height="188" border="0" cellpadding="10" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td valign="top">
<div align="center"><!--#include file="../quotes/callusbandFORM.asp" --></div></td>
</tr>
</table>
<br>
<!-- #BeginLibraryItem "/Library/bottomcopyright.lbi" --><!-- #BeginLibraryItem "/Library/bottomcopyright.lbi" -->
<table width="100%" height="33" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td bgcolor="#666666" class="small"> </td>
</tr>
<tr>
<td height="19" class="small"><div align="center">©2005 Tegner-Miller Insurance Brokers CA License #0466134 </div></td>
</tr>
</table>
<!-- #EndLibraryItem --><!-- #EndLibraryItem -->
</body>
</html>
Poster: John
Dated: Thursday May 26 2005 - 18:44:55 BST
I'm not an ASP coder, but at line 95 you have...
Code:
<!-- #BeginLibraryItem "/Library/bottomcopyright.lbi" --><!-- #BeginLibraryItem "/Library/bottomcopyright.lbi" -->
You're calling the same lib item twice. Looks like a nest to me.
Also, your JS menu calls are incorrect. See the docs that came in the download.
Poster: kevin3442
Dated: Friday May 27 2005 - 3:04:11 BST
Hi,
John wrote:
...Also, your JS menu calls are incorrect. See the docs that came in the download.
I think John hit it with the above, specifically with the following code:
Code:
if(ns4)_d.write("<script language=JavaScript src=mmenuns4.js><\/script>");
else _d.write("<script language=JavaScript src=mmenudom.js><\/script>");
else _d.write("<script language=JavaScript src=mmenudom.js><\/script>");
That code appears inside of another <script> block; hence, it is nested. Replace the above code with the following:
Code:
if(ns4)_d.write("<scr"+"ipt type=text/javascript src=mmenuns4.js><\/scr"+"ipt>");
else _d.write("<scr"+"ipt type=text/javascript src=mmenudom.js><\/scr"+"ipt>");
else _d.write("<scr"+"ipt type=text/javascript src=mmenudom.js><\/scr"+"ipt>");
Breaking up the <script> tag should mask it from the asp server and should solve the problem.
Cheers,
Kevin
Industrial Strength JavaScript and DHTML Menus
About Us
Testimonials
Contact Us
Our Distinguished Clients
Investing in Non-Profits
Where Are We
Privacy Policy
Software Licensing Agreement
DHTML JavaScript Menu
Product Information
Page Integration
Quick Reference Guides
Embedding Into a Table or DIV
Purchase
