MyBB.de Forum
Dynamisch to top - Druckversion

+- MyBB.de Forum (https://www.mybb.de/forum)
+-- Forum: Anpassungen (https://www.mybb.de/forum/forum-47.html)
+--- Forum: Plugin-Diskussionen (https://www.mybb.de/forum/forum-38.html)
+--- Thema: Dynamisch to top (/thread-29946.html)



Dynamisch to top - hkkp - 23.06.2014

hallo,

hab ich bei yaldaram gefunden und dachte mir, dass dies einige gebrauchen könnten. bei mir funktioniert es tadelos.

füge im footer am anfang ein:

PHP-Code:
<script type="text/javascript">
jQuery.noConflict();
jQuery(function($) {
$(
"#backtop").hide();
  $(
window).scroll(function () {
    if ($(
this).scrollTop() > 400) {
      $(
'#backtop').fadeIn(200);
    } else {
      $(
'#backtop').fadeOut(200);
    }
  });
  $(
'.go-top').click(function () {
    $(
'html,body').animate({
      
scrollTop0
    
}, 1000);
    return 
false;
  });
});
</
script

und ganz unten vor den zwei </div>

PHP-Code:
<div id='backtop'>
<
class='go-top' href='#top' title='Zum Seitenanfang'><img src="{$theme['imgdir']}/top.png" alt="" /></a>
</
div

im anhang dann ein weißer pfeil als png, welches transparent ist.


RE: Dynamisch to top - Murphy - 23.06.2014

Hast Du den Code kopiert? Dann füg bitte noch eine Quelle hinzu.


RE: Dynamisch to top - hkkp - 23.06.2014

YALDARAM


RE: Dynamisch to top - MrBrechreiz - 24.06.2014

Hier sind auch noch ein Paar.
http://www.dynamicdrive.com/dynamicindex3/scrolltop.htm
http://www.dynamicdrive.com/dynamicindex5/scrolltotoplink.htm


RE: Dynamisch to top - hkkp - 24.06.2014

PHP-Code:
#backtop {
    
positionfixed;
    
bottom10px;
    
right10px;
    
margin0;
    
padding0;
    
width36px;
    
height36px;
    
z-index100;


hatte ich oben noch vergessen. sorry


RE: Dynamisch to top - Jockl - 24.06.2014

Es gibt auch ein entsprechendes Plugin....
https://www.mybb.de/erweiterungen/16x/plugins-verschiedenes/dynamic-to-top/