PDA

View Full Version : There is some error in this gallery....



Shahla
11-13-2006, 06:04 AM
1) Script Title: CMotion Image Gallery

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex4/cmotiongallery.htm

3) Describe problem: The .js file has some problem in it and the gallery is not working, when i try to preview in Frontpage or IE a little window pops up saying something about error & debugging...I dunno simply anything abot it!... so I press 'no' and the thing pops up again and again and again! after following all the steps ...when i tried to open that file a window pops up saying.....

Script: shows the location of the file here
Line: 29
Char: 1
Error: 'document' is undefined
Code: 800A1391
Source: Microsoft JScript runtime error

Shahla
11-13-2006, 06:15 AM
To be precise the little window says....

A Runtime Error has occurred.
Do you wish to Debug?

Line: 1
Error: Invalid Character


now there are two buttons

Yes and No

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

The Same thing is happing with CMotion Image Gallery II

jscheuer1
11-13-2006, 10:00 AM
The document object can almost never be undefined. Are you having this problem on the demo page?? If not, it is probably your implementation. Can you supply a link to your problem page?

Incidentally, FP is notorious for mangling scripts. Try saving your page in FP with nothing from the script on it. Then open the page in notepad and edit it according to the installation instructions. Preview in the browser and never put it back into FP without a backup copy.

If this is the problem, this might also be of help:


Well, you might be able to configure FP so as to allow you to insert code like this without it mangling it so much. Read the manual or Google for help on that. Another alternative, and what I recommend in all cases like this, is to get your page looking like you want using FP but without any scripts. Save a copy of that somewhere to work on later if the need arises. Next open the page in notepad or simple text and add the scripts in according to the installation instructions, including any customization you've added. Never load this version of the page into FP ever again. To preview it locally, use the browser. To upload it, use FTP (preferred) or your host's online uploading tool.

Here is another solution I ran across* but, since I do not use FP, I haven't tested it:

In a text editor open the page whose code you wish to preserve.

At the beginning of the section of code you wish to prevent FrontPage from modifying, add the following line of code:


<!--webbot bot="HTMLMarkup" startspan -->

At the end of the code section, add the following line of code:


<!--webbot bot="HTMLMarkup" endspan -->

Save the changes to the file. The next time the file is opened in FrontPage, FrontPage will not attempt to alter the code between the two HTMLMarkup tags.

*Posted in these forums by usace-lrc and perhaps others.