PDA

View Full Version : Ultimate Fade-In Slideshow ext file problem



motherandmore
03-10-2006, 11:21 PM
re script:Ultimate Fade-In Slideshow
http://www.dynamicdrive.com/dynamicindex14/fadeinslideshow.htm

Hi there,

I used the slideshow above and loved it (as long as the script was on the page at www.utahbirth.net (http://www.utahbirth.net) (set up with frames) but I'm trying to get rid of the frames now and use an external .js file to call in.
What I'm getting is a blank, black space. Somebody at webdeveloper.com has been trying to help me but I think he's stumped now and the latest change made my drop down menu transparent... www.mygenesisonline.com/utahbirthnet (http://www.mygenesisonline.com/utahbirthnet)

I've learned that it's often difficult to get two scripts to run on the same page, so I've tried taking the menu script off but nothing changes.

I would really love to figure this out.

Thank you in advance for any guidance you can offer.

jscheuer1
03-11-2006, 05:28 AM
There could be other problems but, at the beginning of your external bannerad.js file, you have this:


var fadeimages=new Array()
//SET IMAGE PATHS. Extend or contract array as needed
fadeimages[0]=["fairbanner.jpg", "http://www.utahbirth.net/news.html", "_new"]
fadeimages[1]=["babybanner.jpg", "http://www.utahbirth.net/news.html", "_new"] fadeimages[2]=["genesisbanner.jpg", "http://www.mygenesisonline.com", "_new"]
var fadebgcolor="white"

It should be like so:


var fadeimages=new Array()
//SET IMAGE PATHS. Extend or contract array as needed
fadeimages[0]=["fairbanner.jpg", "http://www.utahbirth.net/news.html", "_new"]
fadeimages[1]=["babybanner.jpg", "http://www.utahbirth.net/news.html", "_new"]
fadeimages[2]=["genesisbanner.jpg", "http://www.mygenesisonline.com", "_new"]

var fadebgcolor="white"

jscheuer1
03-11-2006, 05:46 AM
Oh wait, there's more. On your page you have this:


<link rel="stylesheet" type="text/css" href="utahbirth.css" />

/***********************************************
* Ultimate Fade-In Slideshow (v1.5): Dynamic Drive (http://www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for this script and 100s more.
***********************************************/

<style type="text/css">

The red part shouldn't even be there. The credit should be included with the script call which should be separate from the slideshow call. The script call belongs after the style, it should go here:


font-weight: normal;
}

#dropmenudiv a:hover{ /*hover background color*/
background-color: d8c6e9;
}
</style>

<script type="text/javascript" src="bannerad.js">

/***********************************************
* Ultimate Fade-In Slideshow (v1.5): Dynamic Drive (http://www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for this script and 100s more.
***********************************************/

</script>

<script type="text/javascript" src="dropmenu.js">
/***********************************************
* AnyLink Drop Down Menu- Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/
</script>

Then the later slideshow call should look like so (without the src attribute):


<td style="text-align: center; height: 100px; width: 100%;" bgcolor="black">
<script type="text/javascript">
//new fadeshow(IMAGES_ARRAY_NAME, slideshow_width, slideshow_height, borderwidth, delay, pause (0=no, 1=yes), optionalRandomOrder)
new fadeshow(fadeimages, 140, 225, 0, 3000, 1, "R")
</script>
</td>

There could yet be other problems but, correcting these and the one mentioned in my previous post will be a good start.

motherandmore
03-11-2006, 06:15 AM
Well, that improved my table...and I took the doctype info out, that fixed my drop-down menu that was showing transparent...I'll worry about that later, I guess.

But, the slideshow is still not showing up.

I'm amazed at how quickly you found my errors above, thank you so much...any more hitting you?

jscheuer1
03-11-2006, 07:21 AM
This may be the last major error, at the end of the bannerad.js file, remove this:

</script>

There are a number of css errors and/or irregularities you should take care of because they cannot be helping. Fix the above and see what happens first.

CSS flags:

Error: Selector expected. Ruleset ignored due to bad selector.
Source File: http://www.mygenesisonline.com/utahbirthnet/utahbirth.css
Line: 4

Error: Unrecognized at-rule or error parsing at-rule '@font-face'.
Source File: http://www.mygenesisonline.com/utahbirthnet/utahbirth.css
Line: 7

Error: Unknown property 'decoration'. Declaration dropped.
Source File: http://www.mygenesisonline.com/utahbirthnet/utahbirth.css
Line: 31

Error: Unknown property 'decoration'. Declaration dropped.
Source File: http://www.mygenesisonline.com/utahbirthnet/utahbirth.css
Line: 34

Error: Unknown pseudo-class or pseudo-element 'normal'. Ruleset ignored due to bad selector.
Source File: http://www.mygenesisonline.com/utahbirthnet/utahbirth.css
Line: 35

Error: Unknown pseudo-class or pseudo-element 'normal'. Ruleset ignored due to bad selector.
Source File: http://www.mygenesisonline.com/utahbirthnet/utahbirth.css
Line: 38

Error: Error in parsing value for property 'font'. Declaration dropped.
Source File: http://www.mygenesisonline.com/utahbirthnet/
Line: 12

Error: Expected ':' but found ';'. Declaration dropped.
Source File: http://www.mygenesisonline.com/utahbirthnet/
Line: 13

motherandmore
03-11-2006, 04:52 PM
I had no idea that closing script tag was there...sorry, that was dumb.

But, the banner popped up when I removed above tag and the centering style that shouldn't be there...I'll go see about getting it in my css...

I'm awfully discouraged about all the errors...I need to go learn about the doctype info. When I looked at trying different doctype coding, the wc3 validator kept telling me it was the wrong one. The have info there about it, but none of it makes sense...I'll have to try htmlgoodies...he has any easy way of talking.

Thank you SO much, you've been really great!

Twey
03-11-2006, 05:11 PM
Basically, stick to HTML4.01 Strict unless you know what you're doing.

jscheuer1
03-11-2006, 05:58 PM
I prefer the:


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">

DOCTYPE which is a good one to use if you are used to writing without one. It requires a little adapting to if you are used to no DOCTYPE but, not as much as a strict DOCTYPE does. If you are just starting out, a strict DOCTYPE probably will give you the most consistency across browsers.

About the css errors. Those were picked up by FF1.5.0's javascript console and most are the result of invalid entries in your external stylesheet, some in the style section on the page itself. These are generally just ignored by browsers. Most, if not all, are css errors that would be invalid with any DOCTYPE or even without one. Studying up on proper css syntax and the available selectors, properties and values will help you not to make so many of these kind of errors. Don't feel too bad though, even the most experienced coders make some of these kinds of goofs now and then.