PDA

View Full Version : Cross Browser marquee II help please



SilverWolf
11-12-2007, 06:17 AM
1) Script Title: Cross Browser marquee II

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex2/cmarquee2.htm

3) Describe problem: My problem is I can't get the scroller to sit in the middle of the box. It hugs the right and only shows half of the content. No matter what I try I can't get it to center.

Edits I have made:

<style type="text/css">

#marqueecontainer{
position: relative;
width: 150px; /*marquee width */
height: 200px; /*marquee height */
background-color: sh_bk6.gif;
overflow: hidden;
border: 0px solid orange;
padding: 0px;
padding-left: 0px;
}

</style>
no other edits exsit at this time.


4) My Site: http://pixel2.alittlebitofmagick.com/
this sight is not open to the public yet.

jscheuer1
11-12-2007, 01:51 PM
This is only a problem in IE, it is centering the left edge of the inner (vmarquee) division. Add (red):


<style type="text/css">

#marqueecontainer{
position: relative;
width: 150px; /*marquee width */
height: 200px; /*marquee height */
background-color: sh_bk6.gif; /* this should be a color, not an image */
overflow: hidden;
border: 0px solid orange;
padding: 0px;
padding-left: 0px;
text-align:left;
}

</style>

If after that, you think the text in the marquee needs centering:


#vmarquee {
text-align:center;
}

More about background-color: sh_bk6.gif; /* this should be a color, not an image */:

If you want a background-image do:


background-image:url(sh_bk6.gif);

If you do, or do end up putting a color value there, set a foreground color:


color:black;

Notes: This is a somewhat older script and doesn't work in some browsers that it could. Here is a mod that can make more than one scroller per page and that works in more browsers:

http://home.comcast.net/~jscheuer1/side/v_at_cross_marq_h.htm

SilverWolf
11-12-2007, 05:13 PM
Thank you so much John. Every thing is working great.