Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 02-16-2007, 07:56 PM   PM User | #1
princesjewel
New to the CF scene

 
Join Date: Feb 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
princesjewel is an unknown quantity at this point
Question Photo Slider Error Help

I'm new to website design and have tried the following javascipt:

http://javascriptkit.com/script/script2/pslide.shtml

I have double checked all the characters, and everything is entered exactly like it's said to. But, when I go to preview the slider an error pops up everytime I click on the back, forward or start over buttons. Something like object expected. Is there something else I need to change in the script?
princesjewel is offline   Reply With Quote
Old 02-16-2007, 07:59 PM   PM User | #2
Philip M
Supreme Master coder!

 
Philip M's Avatar
 
Join Date: Jun 2002
Location: London, England
Posts: 17,044
Thanks: 197
Thanked 2,412 Times in 2,390 Posts
Philip M has a spectacular aura aboutPhilip M has a spectacular aura aboutPhilip M has a spectacular aura about
Please tell us exactly what the error message you receive is.

Line
Character
Error
Philip M is online now   Reply With Quote
Old 02-16-2007, 08:16 PM   PM User | #3
princesjewel
New to the CF scene

 
Join Date: Feb 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
princesjewel is an unknown quantity at this point
The error message is slightly different each time. Below is the latest (I noted which areas are different each time):

Line: 64 (this line changes-usually bounces between 61-64)

Char: 1

Error: Object expected

Code: 0

URL: file:///C:/Documents%20and%20Settings/Owner/Local%20Settings?Temp/FrontpageTempDir/Pvw1.htm (The last section of this changes)

Do you want to continue running scripts on this page?
princesjewel is offline   Reply With Quote
Old 02-17-2007, 07:50 AM   PM User | #4
Philip M
Supreme Master coder!

 
Philip M's Avatar
 
Join Date: Jun 2002
Location: London, England
Posts: 17,044
Thanks: 197
Thanked 2,412 Times in 2,390 Posts
Philip M has a spectacular aura aboutPhilip M has a spectacular aura aboutPhilip M has a spectacular aura about
This is a simple script which works well for me in MSIE.

Check carefully that you have copied it exactly and not left out any character (say at the end of a line). If necessary copy the script from the
javascriptkit site once again and paste it in.

Check that it works (does not return errors) even though you have not altered the image URLs.

Remember that Javascript is case sensitive so e.g. Photo is not the same as photo.
Philip M is online now   Reply With Quote
Old 02-18-2007, 06:20 PM   PM User | #5
princesjewel
New to the CF scene

 
Join Date: Feb 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
princesjewel is an unknown quantity at this point
See next posting

Last edited by princesjewel; 02-18-2007 at 06:23 PM..
princesjewel is offline   Reply With Quote
Old 02-18-2007, 06:20 PM   PM User | #6
princesjewel
New to the CF scene

 
Join Date: Feb 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
princesjewel is an unknown quantity at this point
If I copy and paste it, it doesn't paste right. The language is all different in the HTML, and when I look at the page in normal or preview, it shows the language that was supposed to be pasted into HTML, instead it shows it on the page and there are no pictures or scrollers. Is it because I'm using an older Frontpage program? I have typed everything exactly like is says, 3 times and I get the same thing every time. Another thing it does, is it automatically changes things in the HTML after I go to preview it. For example: Where it says:

photos[0]="plane1.gif"
photos[1]='plane2.gif'

I type in my pictures, then when I preview it then go back to the HTML it shows:

photos[0]="
photos[1]="plane2.gif"

This is not the only area that keeps changing. Is it supposed to automatically change?
princesjewel is offline   Reply With Quote
Old 02-18-2007, 07:11 PM   PM User | #7
Philip M
Supreme Master coder!

 
Philip M's Avatar
 
Join Date: Jun 2002
Location: London, England
Posts: 17,044
Thanks: 197
Thanked 2,412 Times in 2,390 Posts
Philip M has a spectacular aura aboutPhilip M has a spectacular aura aboutPhilip M has a spectacular aura about
"Is it because I'm using an older Frontpage program?"

Yes, yes and yes. Frontpage is absolute rubbish. Indeed, all these code generators are pretty poor. You should hand-code using Notetab or similar text editor.
Philip M is online now   Reply With Quote
Old 02-18-2007, 07:41 PM   PM User | #8
princesjewel
New to the CF scene

 
Join Date: Feb 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
princesjewel is an unknown quantity at this point
Pardon me for being dumb, but how do I do that?

Last edited by princesjewel; 02-18-2007 at 07:43 PM..
princesjewel is offline   Reply With Quote
Old 02-18-2007, 08:45 PM   PM User | #9
Philip M
Supreme Master coder!

 
Philip M's Avatar
 
Join Date: Jun 2002
Location: London, England
Posts: 17,044
Thanks: 197
Thanked 2,412 Times in 2,390 Posts
Philip M has a spectacular aura aboutPhilip M has a spectacular aura aboutPhilip M has a spectacular aura about
Quote:
Originally Posted by princesjewel View Post
Pardon me for being dumb, but how do I do that?
By using a plain text editor (e.g. Notetab) or better still CuteHTML which I myself use and find excellent. This means that you have to write out your own code rather than relying on some ghastly generator to do it for you. But this is really the only way to proceed if you are to learn how to do it properly, rather than blindly copying scripts and trying to paste them into your HTML as generated by Frontpage. As you have seen, Frontpage messes things up if you add extra code to it.
Philip M is online now   Reply With Quote
Old 02-20-2007, 05:52 PM   PM User | #10
princesjewel
New to the CF scene

 
Join Date: Feb 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
princesjewel is an unknown quantity at this point
I did hand enter the script through Macroscript Editor originally after I saw the copy paste function didn't work. That's were I am, and it still changes it. I guess I just need to find another software program to design my site. Thanks for the help.
princesjewel is offline   Reply With Quote
Old 02-20-2007, 06:47 PM   PM User | #11
Karen S. Garvin
Regular Coder

 
Karen S. Garvin's Avatar
 
Join Date: Nov 2006
Location: Maryland
Posts: 227
Thanks: 5
Thanked 2 Times in 2 Posts
Karen S. Garvin is on a distinguished road
Quote:
Yes, yes and yes. Frontpage is absolute rubbish. Indeed, all these code generators are pretty poor. You should hand-code using Notetab or similar text editor.
Years ago I bought Macromedia's Backstage Designer. Same thing -- when it didn't understand something it just threw it away. Frontpage is the same concept -- it tries to "fix" things for you, and it's dumber than a rock. It's what I call User Stupid Software.

You're better off hand coding unless you want to spend lots of money on a professional-level web program. Your other alternative is to take the code that FrontPage has already written for you, and then open the code into Notepad, Wordpad, or some other editor, such as alleycode software (it's freeware). Make your changes by hand, then save and NEVER open this file in Frontpage again, or it'll "take out the trash" -- aka your javascript. Keep a copy for Frontpage if you absolutely must use that program for graphics, etc., but don't let it near your good file.
__________________
----------------------------------------------
Karen S. Garvin
http://ksgarvin.wordpress.com
Karen S. Garvin is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

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 On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 07:27 AM.


Advertisement
Log in to turn off these ads.