Log in

View Full Version : Marquee not Working Properly In Advanced_CMP Module



LEAD_WEIGHT
09-12-2005, 09:36 PM
I am trying to get this marquee code to work properly in my advanced_cmp module, but it adds double the space when you click on the controls or sometimes when page is loaded?
If I need to switch to a different code to make it work then which should I get and how to make it work with module.

link to home page of module 'Latest Forum Topics'
http://www.theundergroundsource.com/?


<!-- Latest Threads -->

<table align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" class="tborder" width="100%">
<thead>
<tr>
<td class="tcat"><span class="smallfont"><strong>$vba_options[portal_blockbullet] <span class="smallfont"><strong>$vbphrase[latest_forum_topics]</strong></span></strong></span></td>
</tr>
</thead>
<tr>
<td class="$getbgrow" width="100%">
<MARQUEE name="crawl" id="crawl" behavior="scroll" align= "center" direction= "up" height="250" scrollamount= "2" scrolldelay= "70" onmouseover='this.stop()' onmouseout='this.start()'>
<table align="center" border="0" cellpadding="0" cellspacing="0" width="100%">
<if condition="$mods['modcol'] == 0">
<tr> <if condition="$vba_options['portal_threads_showicon']">
<td class="thead" width="5">&nbsp;</td>
</if>
<td class="thead" width="100%"><span class="smallfont">$vbphrase[title_username_date]</span></td>
<if condition="$show['lastpost']">
<td align="center" class="thead" nowrap="nowrap" width="25%"><span class="smallfont">$vbphrase[last_post]</span></td>
</if>
<td class="thead" width="15"><span class="smallfont">$vbphrase[replies]</span></td>
<td class="thead" width="15"><span class="smallfont">$vbphrase[views]</span></td>
<if condition="$vba_options['portal_threads_showforum']">
<td align="center" class="thead" width="10%"><span class="smallfont">$vbphrase[forum]</span></td>
</if> </tr>
</if>$threadbits
</table>
</MARQUEE>
<div align="center"><hr color="#0000FF" width="75%" size="1"><font size=1 color="#0000FF">Scroll Control:&nbsp;&nbsp;<a href="#" onclick="javascript:crawl.direction=='up'?crawl.direction='down':crawl.direction='up';return false">
<img src="http://www.theundergroundsource.com/forums/images/buttons/reverse.gif" alt="Reverse Direction" border="0"></a>&nbsp;&nbsp;&nbsp;<a href="#" onclick="javascript:crawl.scrollAmount=crawl.scrollAmount/2;return false">
<img src="http://www.theundergroundsource.com/forums/images/buttons/collapse_alt.gif" alt="Slower" border="0"></a>&nbsp;&nbsp;&nbsp;<a href="#" onclick="javascript:crawl.scrollAmount=crawl.scrollAmount+2;return false">
<img src="http://www.theundergroundsource.com/forums/images/buttons/collapse_alt_collapsed.gif" alt="Faster" border="0"></a></font></div>
</td>
</tr>
</table>
<br />

<!-- End Latest Threads -->

Twey
09-13-2005, 09:37 AM
<td class="thead" width="15">
That's a bit of an element abuse. There's a <th> element already available for your table headers. Style that instead.

It looks OK for me (Firefox 1.0.6, Opera, Konqueror); however, I wouldn't recommend using the <marquee> element. Try a Javascript marquee instead. Multiple examples of this can be found here on DD.

LEAD_WEIGHT
09-13-2005, 06:43 PM
JavaScript is going to the death of me. I am going to have to learn that as well, but I am going to learn flash first, then spread out from their.
Thxs Twey for help/info.

*edit
Darn it did not work as I hope. It still makes it double in length?

This is the orginal code


<!-- Latest Threads -->

<table align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" class="tborder" width="100%">
<tr>
<td <if condition="$mods['modcol'] == 1">colspan="6"</if> class="tcat"><span class="smallfont"><strong>$vba_options[portal_blockbullet] $vbphrase[latest_forum_topics]</strong></span></td>
</tr>
<if condition="$mods['modcol'] == 1">
<tr>
<if condition="$vba_options['portal_threads_showicon']">
<td class="thead" width="5">&nbsp;</td>
</if>
<td class="thead" width="100%"><span class="smallfont">$vbphrase[title_username_date]</span></td>
<if condition="$show['lastpost']">
<td align="center" class="thead" nowrap="nowrap" width="25%"><span class="smallfont">$vbphrase[last_post]</span></td>
</if>
<td class="thead" width="15"><span class="smallfont">$vbphrase[replies]</span></td>
<td class="thead" width="15"><span class="smallfont">$vbphrase[views]</span></td>
<if condition="$vba_options['portal_threads_showforum']">
<td align="center" class="thead" width="10%"><span class="smallfont">$vbphrase[forum]</span></td>
</if>
</tr>
</if>
$threadbits
</table>
<br />

<!-- End Latest Threads -->


This <marquee> worked without controls



<!-- Latest Threads -->

<table align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" class="tborder" width="100%">
<thead>
<tr>
<td class="tcat"><span class="smallfont"><strong>$vba_options[portal_blockbullet] <span class="smallfont"><strong>$vbphrase[latest_forum_topics]</strong></span></strong></span></td>
</tr>
</thead>
<tr>
<td class="$getbgrow" width="100%">
<A name="scrollingCode"></A><MARQUEE behavior="scroll" align="center" direction="up" height="220" scrollamount="2" scrolldelay="20" onmouseover="this.stop()" onmouseout="this.start()">
<table align="center" border="0" cellpadding="0" cellspacing="0" width="100%">
<if condition="$mods['modcol'] == 0">
<tr> <if condition="$vba_options['portal_threads_showicon']">
<td class="thead" width="5">&nbsp;</td>
</if>
<td class="thead" width="100%"><span class="smallfont">$vbphrase[title_username_date]</span></td>
<if condition="$show['lastpost']">
<td align="center" class="thead" nowrap="nowrap" width="25%"><span class="smallfont">$vbphrase[last_post]</span></td>
</if>
<td class="thead" width="15"><span class="smallfont">$vbphrase[replies]</span></td>
<td class="thead" width="15"><span class="smallfont">$vbphrase[views]</span></td>
<if condition="$vba_options['portal_threads_showforum']">
<td align="center" class="thead" width="10%"><span class="smallfont">$vbphrase[forum]</span></td>
</if> </tr>
</if>$threadbits
</table>
</MARQUEE>
</td>
</tr>
</table>
<br />

<!-- End Latest Threads -->