Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Beginning Dreamweaver MX/MX 2004 MX ISBN: 978-0-7645-4404-0; MX 2004 ISBN: 978-0-7645-5524-4
This is the forum to discuss the Wrox book Beginning Dreamweaver MX by Charles E. Brown, Imar Spaanjaars, Todd Marks; ISBN: 9780764544040
Please indicate which version of the book you are using when posting questions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning Dreamweaver MX/MX 2004 MX ISBN: 978-0-7645-4404-0; MX 2004 ISBN: 978-0-7645-5524-4 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 17th, 2004, 07:18 AM
Authorized User
 
Join Date: Sep 2003
Location: Dubai, Dubai, United Arab Emirates.
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Default Error in blockNav.asp page – Page 651 (DW-MX)

Hi Imar!

I have almost finished the mediaEdge web site. It is working except for one problem. The following happens:

When I open index.asp page, it shows as it should – with all the small frames and main frame. But when I click on any item in any frame – say, for example, if I click on Item Two in frame 2a – then totally blank page opens in that particular frame. (The rest of the frames remain unchanged). At the same time on the taskbar there is a message – Error on page. After clicking on that error, the following error message is shown:
--------------------------------------------------------------------
Line:12
Char:3
Error: ‘parent.frameMain.location’ is null or not an object
Code:0
URL: http://localhost/mediaedge/blockNav.asp/sectionID=5

I have compared the code with that in the code download and it matches exactly. Even the databases and the values are the same.

Can you help me please?

Shubhada.



  #2 (permalink)  
Old May 17th, 2004, 07:47 AM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hmmm, did you also check the code for the frameset? How does it look? Do you have a frame called frameMain?

Imar
  #3 (permalink)  
Old May 17th, 2004, 08:16 AM
Authorized User
 
Join Date: Sep 2003
Location: Dubai, Dubai, United Arab Emirates.
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes. There is frameMain in index.asp
Here is the relevant code of index.asp:

-----------------------------------------------

<%@LANGUAGE="JAVASCRIPT" CODEPAGE="1252"%>
<html>
<head>
<title>MediaEdge</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
...........
<link href="blockStyles.css" rel="stylesheet" type="text/css">
</head>

<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onLoad="this.open('blockNav.asp?sectionID=8', 'navigation')">
<table width="760" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td height="33"> <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="190" height="33">
        <param name="movie" value="search.swf">
        <param name="quality" value="high">
        <embed src="search.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="190" height="33"></embed></object></td>
    <td height="33">
    <iFrame name="navigation" width="100%" height="100%" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iFrame></td>
    <td height="33">&nbsp;</td>
    <td height="33"><img src="images/logo.gif" width="190" height="33"></td>
  </tr>
  <tr>
    <td height="205">
    <iFrame name="frame1a" width="100%" height="100%" scrolling="no" marginwidth="0" marginheight="0" frameborder="0">Please
    upgrade your browser</iFrame></td>
    <td height="205" colspan="3">
    <iFrame name="frameMain" width="100%" height="100%" scrolling="no" marginwidth="0" marginheight="0" frameborder="0">Please
    upgrade your browser</iFrame></td>
  </tr>
  <tr>
    <td height="39" colspan="4">&nbsp;</td>
  </tr>
  <tr>
    <td width="190" height="143">
    <iFrame name="frame2a" width="100%" height="100%" scrolling="no" marginwidth="0" marginheight="0" frameborder="0">Please
    upgrade your browser</iFrame></td>
    <td width="190" height="143">
    <iFrame name="frame2b" width="100%" height="100%" scrolling="no" marginwidth="0" marginheight="0" frameborder="0">Please
    upgrade your browser</iFrame></td>
    <td width="190" height="143">
    <iFrame name="frame2c" width="100%" height="100%" scrolling="no" marginwidth="0" marginheight="0" frameborder="0">Please
    upgrade your browser</iFrame></td>
    <td width="190" height="143">
    <iFrame name="frame2d" width="100%" height="100%" scrolling="no" marginwidth="0" marginheight="0" frameborder="0">Please
    upgrade your browser</iFrame></td>
  </tr>
</table>
</body>
</html>

-----------------------------------------

Shubhada.



  #4 (permalink)  
Old May 17th, 2004, 08:22 AM
Authorized User
 
Join Date: Sep 2003
Location: Dubai, Dubai, United Arab Emirates.
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Default

In blockNav.asp also frameMain is specified correctly.

----------------------------------------------
if (Navigation.BOF && Navigation.EOF) {
    var frameMain = Navigation__MMColParam.replace(/'/g, "''") + "";
    var frame1a = 0;
    var frame2a = 0;
    var frame2b = 0;
    var frame2c = 0;
    var frame2d = 0;
  } else {
    var frameMain = Navigation.Fields.Item("Section_ID").Value;
    var frame1a = Navigation.Fields.Item("frame1a").Value;
    var frame2a = Navigation.Fields.Item("frame2a").Value;
    var frame2b = Navigation.Fields.Item("frame2b").Value;
    var frame2c = Navigation.Fields.Item("frame2c").Value;
    var frame2d = Navigation.Fields.Item("frame2d").Value;
  }
---------------------------------------------------------

Shubhada.

  #5 (permalink)  
Old May 17th, 2004, 08:58 AM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

And how does the source for the link look like? I mean the source for the page that generates the error in the browser.

Do you think the error message is correct? That is, is the page that generates the error on the same level as frameMain? Is frameMain accessible through the "parent" of the page that gives the error?

And more importantly: does the code download work, or do you get the same error?

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
  #6 (permalink)  
Old May 17th, 2004, 11:37 AM
Authorized User
 
Join Date: Sep 2003
Location: Dubai, Dubai, United Arab Emirates.
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The page that generates error is blockNav.asp

I have not pasted the code for that file here because when I copied and pasted the code from the code download to this file and tested the same error message was generated. So there must be nothing wrong with the code itself.

I did not get you when you say 'the page generating the error being on the same level as the frameMain'. If I get you correctly, index.asp defines frameMain. index.asp calls blockNav.asp. Both index.asp and blockNav.asp are created in the site folder mediaEdge.

Some additional information:
In Sections_Nav table there are only 2 records as follows:

Section_ID frame1a frame2a frame2b frame2c frame2d
---------- ------- ------- ------- ------- -------
    2 0 1 1 1 1
    8 9 1 1 1 1
---------------------------------------------------------
where 2 is the section_ID of the BuildingBlock_Main and 8 is the section_ID of Intro.

However the section_IDs of Item One through Item Five are 3 to 7, which are not in the Sections_Nav table.

I don't know whether this information is relevant, but when I click on - say - Item One, the ID generated will be 3, which is not there in the Sections_Nav table. Does this have anything to do with the above problem?

Shubhada.

  #7 (permalink)  
Old May 17th, 2004, 02:57 PM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi Shubhada,

Are you working on Chapter 18? If so, did you use the database for Chapter 18, or are you still working with the database from the previous chapter?

The Chapter 17 database contains just 1 section, while the other contains lots more.

Todd has written the MediaEdge site, and the part in the book about. Maybe he's reading this as well and can jump in for help....

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
  #8 (permalink)  
Old May 18th, 2004, 12:03 AM
Authorized User
 
Join Date: Sep 2003
Location: Dubai, Dubai, United Arab Emirates.
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes, I am working on chapter 18. And the database I am using is also from chapter 18. In fact I checked the database for chapter 18 from the code download, and that also contains just 2 records, with the same values as mine.

But, even when I inserted another record - just for trial - in the database, it still generated the same error.

I guessed from the writing style that the author of the MediaEdge site was different from the author of the previous site. I hope he is reading this too and help me..

Shubhada.

  #9 (permalink)  
Old May 18th, 2004, 05:30 AM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Well, the Sections_Nav table contains the same two records, but the Sections table contains more records in Chapter 18 than in 17.....

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
  #10 (permalink)  
Old May 18th, 2004, 08:03 AM
Authorized User
 
Join Date: Sep 2003
Location: Dubai, Dubai, United Arab Emirates.
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes, the Sections table has 10 records. I have them all - mine are the same as the ones in the code download.

Then I don't think anything is wrong with my database. May be something is missing in some asp file which is generating the error message. But the code for the blockNav.asp in my site is the same as that in the code download. So may be the error lies somewhere else.

Shubhada.

 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off




All times are GMT -4. The time now is 08:33 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.