Möchte auch so einen Gif-Regen...

    Diese Seite verwendet Cookies. Durch die Nutzung unserer Seite erklären Sie sich damit einverstanden, dass wir Cookies setzen. Weitere Informationen

    • Möchte auch so einen Gif-Regen...

      hallo Ihr Lieben!

      Ich liebe Eure Smilies und hab mich jetzt mal hier angemeldet. ich möchte dreisterweise mal fragen, wie das mit diesem Schneeflockenregen auf der Startseite von Cheesebürger funzt... :rolleyes:

      Hab 2 (kostenlose) HP's und "manage" eine "richtige" für meinen Freund... und für meine 2 kostenlosen möchte ich sowas auch so gerne mal haben...

      Verrät mir einer das Geheimnis?
      Vielen Dank und Liebe Grüßchen

      Jessi
    • Diese Schneescripte findest du wie Sand am Meer auf Webmasterseiten.

      Hier ist ein Beispiel das sogar funktioniert. :D

      Quellcode

      1. <script language="JavaScript1.2">
      2. <!--
      3. var snowsrc="snow.gif"
      4. var no = 10;
      5. var ns4up = (document.layers) ? 1 : 0;
      6. var ie4up = (document.all) ? 1 : 0;
      7. var dx, xp, yp;
      8. var am, stx, sty;
      9. var i, doc_width = 1024, doc_height = 768;
      10. if (ns4up) {
      11. doc_width = self.innerWidth;
      12. doc_height = self.innerHeight;
      13. } else if (ie4up) {
      14. doc_width = document.body.clientWidth;
      15. doc_height = document.body.clientHeight;
      16. }
      17. dx = new Array();
      18. xp = new Array();
      19. yp = new Array();
      20. am = new Array();
      21. stx = new Array();
      22. sty = new Array();
      23. for (i = 0; i < no; ++ i) {
      24. dx[i] = 0;
      25. xp[i] = Math.random()*(doc_width-50);
      26. yp[i] = Math.random()*doc_height;
      27. am[i] = Math.random()*20;
      28. stx[i] = 0.02 + Math.random()/10;
      29. sty[i] = 0.7 + Math.random();
      30. if (ns4up) {
      31. if (i == 0) {
      32. document.write("<layer name=\"dot"+ i +"\" left=\"15\" top=\"15\" visibility=\"show\"><a href=\"http://www.jswelt.de/\"><img src='"+snowsrc+"' border=\"0\"></a></layer>");
      33. } else {
      34. document.write("<layer name=\"dot"+ i +"\" left=\"15\" top=\"15\" visibility=\"show\"><img src='"+snowsrc+"' border=\"0\"></layer>");
      35. }
      36. } else if (ie4up) {
      37. if (i == 0) {
      38. document.write("<div id=\"dot"+ i +"\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: 15px;\"><a href=\"http://java.topcool.de\"><img src='"+snowsrc+"' border=\"0\"></a></div>");
      39. } else {
      40. document.write("<div id=\"dot"+ i +"\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: 15px;\"><img src='"+snowsrc+"' border=\"0\"></div>");
      41. }
      42. }
      43. }
      44. function snowNS() {
      45. for (i = 0; i < no; ++ i) {
      46. yp[i] += sty[i];
      47. if (yp[i] > doc_height-50) {
      48. xp[i] = Math.random()*(doc_width-am[i]-30);
      49. yp[i] = 0;
      50. stx[i] = 0.02 + Math.random()/10;
      51. sty[i] = 0.7 + Math.random();
      52. doc_width = self.innerWidth;
      53. doc_height = self.innerHeight;
      54. }
      55. dx[i] += stx[i];
      56. document.layers["dot"+i].top = yp[i];
      57. document.layers["dot"+i].left = xp[i] + am[i]*Math.sin(dx[i]);
      58. }
      59. setTimeout("snowNS()", 10);
      60. }
      61. function snowIE() {
      62. for (i = 0; i < no; ++ i) {
      63. yp[i] += sty[i];
      64. if (yp[i] > doc_height-50) {
      65. xp[i] = Math.random()*(doc_width-am[i]-30);
      66. yp[i] = 0;
      67. stx[i] = 0.02 + Math.random()/10;
      68. sty[i] = 0.7 + Math.random();
      69. doc_width = document.body.clientWidth;
      70. doc_height = document.body.clientHeight;
      71. }
      72. dx[i] += stx[i];
      73. document.all["dot"+i].style.pixelTop = yp[i];
      74. document.all["dot"+i].style.pixelLeft = xp[i] + am[i]*Math.sin(dx[i]);
      75. }
      76. setTimeout("snowIE()", 10);
      77. }
      78. if (ns4up) {
      79. snowNS();
      80. } else if (ie4up) {
      81. snowIE();
      82. }
      83. // -->
      84. </script>
      Alles anzeigen

      Dazu folgendes Gif in das selbe Verzeichnis laden in der die betreffende HTML-Datei liegt.
      Bilder
      • snow.gif

        205 Byte, 12×13, 1.217 mal angesehen
    • Danke Dir, doch bei diesen kostenlosen seiten ist das alles recht blöd... X(

      das script an sich funzt, doch rieseln dann Kästchen mit dem berühmten roten Kreuzchen drin... *nachdachte* und ersetzte die im Script erschienenen Gif-URL's mit denen des Gifs, welches ich hochgeladen hatte. (verstehst? ?()

      Dann sind zwar Flocken zu sehen, doch die rieseln nicht mehr. :(
    • Ich hab den Code mal so umgeschrieben, daß er in allen Browsern läuft.

      Brainfuck-Quellcode

      1. <script type="text/javascript">
      2. <!--
      3. var no = 50; // Anzahl der Schneeflocken
      4. var speed = 40; // "Schnei-Geschwindigkeit"; je kleiner die Zahl, um so schneller fallen die Flocken
      5. var snowflake = "snow.gif"; // Bild der Schneeflocke, beliebig
      6. // ***** Ab hier nichts mehr ändern! ********************
      7. var ns4up = (navigator.appName=="Netscape" && navigator.appVersion.charAt(0)=="4") ? 1 : 0; // Browser Tester
      8. var ie4up = (document.all) ? 1 : 0;
      9. var ns6up = (document.getElementById&&!document.all) ? 1 : 0;
      10. var dx, xp, yp; // Variablen für Koordinaten und Position
      11. var am, stx, sty; //Variablen für Amplitude und Schrittweite
      12. var i, doc_width = 800, doc_height = 100;
      13. if (ns4up||ns6up) { // Bildschirm-Auflösung holen, Netscape-Funktion
      14. doc_width = self.innerWidth;
      15. doc_height = self.innerHeight;
      16. } else if (ie4up) { // Bildschirm-Auflösung holen, Internet Explorer-Funktion
      17. doc_width = document.body.clientWidth;
      18. doc_height = document.body.clientHeight;
      19. }
      20. dx = new Array();
      21. xp = new Array();
      22. yp = new Array();
      23. am = new Array();
      24. stx = new Array();
      25. sty = new Array();
      26. for (i = 0; i < no; ++ i) {
      27. dx[i] = 0; // Koordinaten-Variable setzen
      28. xp[i] = Math.random()*(doc_width-50); // Position-Variable setzen
      29. yp[i] = Math.random()*doc_height;
      30. am[i] = Math.random()*20; // Amplituden-Variable setzten
      31. stx[i] = 0.02 + Math.random()/10; // Variable für Schrittweite setzen
      32. sty[i] = 0.7 + Math.random(); // Variable für Schrittweite setzen
      33. // ----------------------------------------------------------------------
      34. // Layer konfigurieren für Netscape
      35. if (ns4up) {
      36. if (i == 0) {
      37. document.write("<layer name=\"dot"+ i +"\" left=\"15\" ");
      38. document.write("top=\"15\" visibility=\"show\"><img src=\"");
      39. document.write(snowflake + "\" border=\"0\"></layer>");
      40. } else {
      41. document.write("<layer name=\"dot"+ i +"\" left=\"15\" ");
      42. document.write("top=\"15\" visibility=\"show\"><img src=\"");
      43. document.write(snowflake + "\" border=\"0\"></layer>");
      44. }
      45. // ----------------------------------------------------------------------
      46. // Layer konfigurieren für <> NS4
      47. } else if (ie4up||ns6up) {
      48. if (i == 0) {
      49. document.write("<div id=\"dot"+ i +"\" style=\"POSITION: ");
      50. document.write("absolute; Z-INDEX: "+ i +"; VISIBILITY: ");
      51. document.write("visible; TOP: 15px; LEFT: 15px;\"><img src=\"");
      52. document.write(snowflake + "\" border=\"0\"></div>");
      53. } else {
      54. document.write("<div id=\"dot"+ i +"\" style=\"POSITION: ");
      55. document.write("absolute; Z-INDEX: "+ i +"; VISIBILITY: ");
      56. document.write("visible; TOP: 15px; LEFT: 15px;\"><img src=\"");
      57. document.write(snowflake + "\" border=\"0\"></div>");
      58. }
      59. }
      60. }
      61. // ----------------------------------------------------------------------
      62. // Haupt-Animations-Funktion für Netscape4
      63. function snowNS() {
      64. for (i = 0; i < no; ++ i) {
      65. yp[i] += sty[i];
      66. if (yp[i] > doc_height-50) {
      67. xp[i] = Math.random()*(doc_width-am[i]-30);
      68. yp[i] = 0;
      69. stx[i] = 0.02 + Math.random()/10;
      70. sty[i] = 0.7 + Math.random();
      71. doc_width = self.innerWidth;
      72. doc_height = self.innerHeight;
      73. }
      74. dx[i] += stx[i];
      75. document.layers["dot"+i].top = yp[i];
      76. document.layers["dot"+i].left = xp[i] + am[i]*Math.sin(dx[i]);
      77. }
      78. setTimeout("snowNS()", speed);
      79. }
      80. // ----------------------------------------------------------------------
      81. // Haupt-Animations-Funktion für Internet Explorer
      82. function snowIE() {
      83. for (i = 0; i < no; ++ i) {
      84. yp[i] += sty[i];
      85. if (yp[i] > doc_height-50) {
      86. xp[i] = Math.random()*(doc_width-am[i]-30);
      87. yp[i] = 0;
      88. stx[i] = 0.02 + Math.random()/10;
      89. sty[i] = 0.7 + Math.random();
      90. doc_width = document.body.clientWidth;
      91. doc_height = document.body.clientHeight;
      92. }
      93. dx[i] += stx[i];
      94. document.all["dot"+i].style.pixelTop = yp[i];
      95. document.all["dot"+i].style.pixelLeft = xp[i] + am[i]*Math.sin(dx[i]);
      96. }
      97. setTimeout("snowIE()", speed);
      98. }
      99. // Haupt-Animations-Funktion für Netscape6 und Mozilla
      100. function snowNS6() {
      101. for (i = 0; i < no; ++ i) {
      102. yp[i] += sty[i];
      103. if (yp[i] > doc_height-50) {
      104. xp[i] = Math.random()*(doc_width-am[i]-30);
      105. yp[i] = 0;
      106. stx[i] = 0.02 + Math.random()/10;
      107. sty[i] = 0.7 + Math.random();
      108. doc_width = self.innerWidth;
      109. doc_height = self.innerHeight;
      110. }
      111. dx[i] += stx[i];
      112. document.getElementById("dot"+i).style.top = yp[i]+"px";
      113. document.getElementById("dot"+i).style.left = xp[i] + am[i]*Math.sin(dx[i])+"px";
      114. }
      115. setTimeout("snowNS6()", speed);
      116. }
      117. if (ns4up) {
      118. snowNS();
      119. } else if (ie4up) {
      120. snowIE();
      121. }else if (ns6up) {
      122. snowNS6();
      123. }
      124. // End -->
      125. </script>
      Alles anzeigen
    • Danke für all die Mühe... also an sich gehts ja... die besagte HP...

      jetzt besteht mein popliger Quelltext daraus:

      <blockquote dir="ltr" style="MARGIN-RIGHT: 0px"><p><font face="arial,helvetica,sans-serif" color="#996633" size="6"><strong><em>Willkommen!<img alt="uj" src="http://nasenbilder.12m.de/files/nasenbilder/snow.gif" align="baseline" /></em></strong></font></p><p><font face="Jester" color="#996633" size="4">Ich freue mich, dass Du diese Seite entdeckt hast!</font></p></blockquote><blockquote><p align="left"><font face="Jester" size="4"><font color="#996633">Nachdem auf meiner ersten Homepage über meinen </font><a href="http://www.hundegeier.12m.de/"><font color="#663300">Hund Nina und ihren Geier</font><font color="#996633"> </font></a><font color="#996633"> die Galerien, insbesondere die Nasenbildergalerie so gut ankamen, möchte ich nun den Nasenbildern eine eigene Seite gönnen. Ich möchte hier meine eigenen Bilder zeigen und auch gelungene Bilder von Bekannten, Verwandten und lieben Leuten aus meinem Lieblingsforum!</font></font></p><p align="left"><font face="Jester" color="#996633" size="4">Habt Ihr auch ein Nasenbild? Wenn Ihr möchtet, könnt Ihr es mir schicken, ich würde mich sehr freuen! Natürlich kann ich Euch, bzw. Euren Hund auch namentlich erwähnen und / oder Euer Kürzel auf das Bild setzen!</font></p><p align="left"><font face="Jester" color="#996633" size="4">Ich hoffe, die Seite gefällt Euch, Ihr könnt ein bisschen lachen und habt Spaß!</font></p><p align="left"><b><font face="HandPrinting" color="#996633" size="6">Lieben Gruss</font></b></p><p align="left"> </p><p align="left"><b><font face="HandPrinting" color="#996633" size="6">die Jessi</font></b></p><a href="http://einzellangohren.reizi.de/" target="_blank"><img alt="Xmasbanner" src="http://hundegeier.12m.de/files/hundegeier/Degu.jpg" /> </a><p align="left"><strong><font face="HandPrinting" color="#996633" size="6"></font></strong></p><p align="left" /><div id="layer1" style="Z-INDEX: 1; LEFT: 0px; WIDTH: 67px; POSITION: absolute; TOP: 20px; HEIGHT: 58px"> </div></blockquote><p align="center"> </p><p align="center"><a href="http://424024.guestbook.onetwomax.de/"><img alt="guestbook" src="http://nasenbilder.12m.de/files/nasenbilder/Unbena.png" align="baseline" /></a> </p>


      Tada... keine wirklichen tags... :(

      ich weiß, ich hab Sonderwünsche... aber wie funzt das da? Wo muss ich das Script hinfügen? Ich habs jetzt in "meiner Not" :) über den oben gezeigten Text gesetzt... und wie gesagt, es rieselt Kästchen... ändere ich im Script die URL des Gifs, rieselts nicht mehr. ;(