aboutsummaryrefslogtreecommitdiffstats
path: root/view/theme/diabook/theme.php
diff options
context:
space:
mode:
authortommy tomson <thomas.bierey@gmx.de>2012-04-25 00:19:57 +0200
committertommy tomson <thomas.bierey@gmx.de>2012-04-25 00:19:57 +0200
commit08b990a314286d12cd39e4c90a69c2ffd33d10dc (patch)
tree2e2235616c390fa8fbb8c479cb9361a304d60e53 /view/theme/diabook/theme.php
parent5ebc221c28e262857bc60de642c73fdad6f1387d (diff)
downloadvolse-hubzilla-08b990a314286d12cd39e4c90a69c2ffd33d10dc.tar.gz
volse-hubzilla-08b990a314286d12cd39e4c90a69c2ffd33d10dc.tar.bz2
volse-hubzilla-08b990a314286d12cd39e4c90a69c2ffd33d10dc.zip
diabook-themes: small fix
Diffstat (limited to 'view/theme/diabook/theme.php')
-rwxr-xr-xview/theme/diabook/theme.php37
1 files changed, 30 insertions, 7 deletions
diff --git a/view/theme/diabook/theme.php b/view/theme/diabook/theme.php
index 269015d0a..073e270ef 100755
--- a/view/theme/diabook/theme.php
+++ b/view/theme/diabook/theme.php
@@ -356,25 +356,48 @@ $(document).ready(function() {
$(this).attr("src",newString+"?"+wmode+"&"+oldString);
}
else $(this).attr("src",ifr_source+"?"+wmode);
+
});
-
- $("a[href=#top]").click(function() {
- $("html, body").animate({scrollTop:0}, "slow");
- return false;
- });
-
});
function yt_iframe() {
-
$("iframe").load(function() {
var ifr_src = $(this).contents().find("body iframe").attr("src");
$("iframe").contents().find("body iframe").attr("src", ifr_src+"&wmode=transparent");
});
};
+
+function scrolldown(){
+ $("html, body").animate({scrollTop:$(document).height()}, "slow");
+ return false;
+ };
+
+function scrolltop(){
+ $("html, body").animate({scrollTop:0}, "slow");
+ return false;
+ };
+
+$(window).scroll(function () {
+
+
+ var scrollInfo = $(window).scrollTop();
+
+ if (scrollInfo <= "900"){
+ $("a#top").attr("id","down");
+ $("a#down").attr("onclick","scrolldown()");
+ $("img#scroll_top_bottom").attr("src","view/theme/diabook/icons/scroll_bottom.png");
+ }
+
+ if (scrollInfo > "900"){
+ $("a#down").attr("id","top");
+ $("a#top").attr("onclick","scrolltop()");
+ $("img#scroll_top_bottom").attr("src","view/theme/diabook/icons/scroll_top.png");
+ }
+
+ });
</script>';