View Single Post
  #5 (permalink)  
Old 09-12-2008, 12:46 AM
method20 method20 is offline
Casual Pligger
 
Join Date: May 2008
Posts: 50
Thanks: 16
Thanked 5 Times in 5 Posts
I have a working Marquee js. It is from dynamic drive but does the same. I added an include to scroll the top stories of the whole site on the front page, and it will change to show the top stories in a category, when in it. Download the ZIP

And add marquee.js in the js folder, and put marquee_stories in the root.

open pligg.tpl and put in the <head> section;

Code:
<script src="{$my_pligg_base}/js/marquee.js" type="text/javascript"></script>
open index_center.tpl and put at the top;
Code:
	{if $pagename neq "story"}
<div id="marqueecontainer" onMouseover="copyspeed=pausespeed" onMouseout="copyspeed=marqueespeed">
<div id="vmarquee" style="position: absolute; width: 98%;">

  {* ----- show the marquee ----- *}

    {php}include('marquee_stories.php');{/php}

{* ---------------------------------------- *} 

</div>
</div>{/if}
And in your templates CSS file add;
Code:
#marqueecontainer{
position: relative;
width: 500px; /*marquee width */
height: 100px; /*marquee height */
background-color:#ffffff;
overflow: hidden;
border:1px solid #000000;
padding: 2px;
padding-left: 4px;
margin-left:100px;
Obviously you can change those values to fit your site.
Attached Files
File Type: zip marquee.zip (1.9 KB, 10 views)
__________________
OSS Supporter.

Last edited by method20; 09-12-2008 at 12:59 AM..
Reply With Quote
The Following User Says Thank You to method20 For This Useful Post: