• Seite 1 von 1
  • 1
Gemeinschaft uCoz » Für Webmaster » Tools & Scripts » Scroll on top/Scroll to top (Der "Scroll on top" vom Ucoz Forum)
Scroll on top/Scroll to top
Aliekber
Beiträge: 4
Ruf: 0
Beitrag # 1 | 17:30
Guten Tag, ich möchte gerne den HTML-Code vom Scroll-on-top auf dieser Webseite gerne haben, weil sie mir sehr gefällt. Ich habe im Seitenquelltext etwas nachgeschaut, doch leider nichts gefunden. Es wäre nett, wenn Sie mir schnell wie möglich antworten können.
Danke!
MfG Aliekber
Beitrag wurde von Aliekber - Samstag, 25.10.2014, 17:31 bearbeitet
bigblog
Beiträge: 30
Ruf: 3
Beitrag # 2 | 21:27
Aliekber, guten tag. Sorry for english answer, but I don't speak German, and I don't want to say something wrong biggrin

Go to Control Panel >> Design management >> Bottom part of the website, and insert this code after the template's code:

Code
<a href="#" class="scrollup"><span align="right" alt="Go to top" title="Go to top" style="bottom:0px; right:20px; z-index:100; position:fixed; width:100px; height:100px;"> BUTTON CONTENT </span> </a>
<script type="text/javascript">  
$(document).ready(function(){  

$(window).scroll(function(){  
if ($(this).scrollTop() > 400) {  
$('.scrollup').fadeIn();  
} else {  
$('.scrollup').fadeOut();  
}  
});  

$('.scrollup').click(function(){  
$("html, body").animate({ scrollTop: 0 }, 1500);  
return false;  
});  

});  

</script>


You can replace BUTTON CONTENT with any HTML code (e.g: an image).

uCoz Administration
Aliekber
Beiträge: 4
Ruf: 0
Beitrag # 3 | 11:17
bigblog, thank you very much but I also would like to have the pic, because I don't know how I add a pic.
Beitrag wurde von Aliekber - Sonntag, 26.10.2014, 11:25 bearbeitet
bigblog
Beiträge: 30
Ruf: 3
Beitrag # 4 | 12:24
Aliekber, use the image code:

Code
<img src="IMAGE URL" />


Replace IMAGE URL with your image's URL address. For example: http://forum.ucoz.ru/images/up.png

uCoz Administration
Aliekber
Beiträge: 4
Ruf: 0
Beitrag # 5 | 17:08
bigblog, I don't know where I should add the HTML code.
Kasach
Beiträge: 726
Ruf: 13
Beitrag # 6 | 20:54
German:
Aliekber, es ist dir überlassen, wo du es einbaust. Wir können es leider nicht Mundgerecht verpacken, da es jeder anders haben will sowie es von Design zu Design anders ist, daher können wir dir nur einen Code geben, den musst du schon selbst irgendwo einbauen.

Hier ein beispiel, für Go to Top als Bild:
Code
<a href="#" class="scrollup"><span align="right" alt="Go to top" title="Go to top" style="bottom:0px; right:20px; z-index:100; position:fixed; width:100px; height:100px;"><img src="http://DEIN-BILD-HIER.jpg" /></span> </a>   
<script type="text/javascript">    
$(document).ready(function(){    

$(window).scroll(function(){    
if ($(this).scrollTop() > 400) {    
$('.scrollup').fadeIn();    
} else {    
$('.scrollup').fadeOut();    
}    
});    

$('.scrollup').click(function(){    
$("html, body").animate({ scrollTop: 0 }, 1500);    
return false;    
});    

});    

</script>


English:
Aliekber, its up to you where you want to place it. We cant adapt it, how you do need it, because everyone wants it a lil bit other and it also depends on the template you are using. We only can give you a snippet and you have to put it at the right place.

Here is an example, with an go to top image:
Code
<a href="#" class="scrollup"><span align="right" alt="Go to top" title="Go to top" style="bottom:0px; right:20px; z-index:100; position:fixed; width:100px; height:100px;"><img src="http://DEIN-BILD-HIER.jpg" /></span> </a>   
<script type="text/javascript">    
$(document).ready(function(){    

$(window).scroll(function(){    
if ($(this).scrollTop() > 400) {    
$('.scrollup').fadeIn();    
} else {    
$('.scrollup').fadeOut();    
}    
});    

$('.scrollup').click(function(){    
$("html, body").animate({ scrollTop: 0 }, 1500);    
return false;    
});    

});    

</script>


Mit freundlichen Grüßen // With greetings
Kasach

Neu bei der uCoz Gemeinschaft? Lese unseren Willkommens Thread.
Aliekber
Beiträge: 4
Ruf: 0
Beitrag # 7 | 11:09
Kasach, vielen Dank. smile
Gemeinschaft uCoz » Für Webmaster » Tools & Scripts » Scroll on top/Scroll to top (Der "Scroll on top" vom Ucoz Forum)
  • Seite 1 von 1
  • 1
Suche: