add fancy scrolling effect > Invisionize.eu - IP.Board (IPB) News
Kanał Rss Kanał Rss
Kanał Atom Kanał Atom

add fancy scrolling effect

wersja drukowalna wersja Microsoft Word wersja HTML

demo

click on http://www.crtaci.info/style_images/freshair/p_up.png

this effect is made with jquery. this is what you need to do:

acp -> Edit Board Header & Footer Wrapper

under <% JAVASCRIPT %> add:

	<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
	<script src="jscripts/jquery.scroll.pack.js" type="text/javascript"></script>
	<script type="text/javascript">
		$(function() {
			$(".toTop").scrollToTop();
		});
	</script>


after that save this js and upload it to jscripts/jquery.scroll.pack.js

http://www.crtaci.in....scroll.pack.js

After this all you have to do is to add class "toTop" to any element you want to scroll you to top when you click it... :) If you want to replace the default "to top" button with this effect, this is what you need to do:

ACP -> Look & Feel -> Edit Template HTML -> Topic View -> render row

find:

<div style='text-align:left'><a href="java script:scroll(0,0);"><{P_UP}></a>{$post['report_link']}</div>


replace with

<div style='text-align:left'><a style="cursor:pointer;" title="Go back to top of page" class="toTop" href="#"><{P_UP}></a>{$post['report_link']}</div>

wto, 18 maj 2010

Komentarze:

Brak komentarzy

Imię/Nick:

Adres email:

Strona WWW:

Treść Komentarza: