PSD-Tutorials.de
Forum für Design, Fotografie & Bildbearbeitung
Tutkit
Agentur
Hilfe
Kontakt
Start
Forum
Aktuelles
Besonderer Inhalt
Foren durchsuchen
Tutorials
News
Anmelden
Kostenlos registrieren
Aktuelles
Suche
Suche
Nur Titel durchsuchen
Von:
Menü
Anmelden
Kostenlos registrieren
App installieren
Installieren
JavaScript ist deaktiviert. Für eine bessere Darstellung aktiviere bitte JavaScript in deinem Browser, bevor du fortfährst.
Du verwendest einen veralteten Browser. Es ist möglich, dass diese oder andere Websites nicht korrekt angezeigt werden.
Du solltest ein Upgrade durchführen oder einen
alternativen Browser
verwenden.
Antworten auf deine Fragen:
Neues Thema erstellen
Start
Forum
Sonstiges
Webdesign, Webentwicklung & Programmierung
Webdesign: HTML/CSS, Responsive Design, Sass...
Bilder rütteln
Beitrag
<blockquote data-quote="cebito" data-source="post: 868201" data-attributes="member: 173078"><p><strong>AW: Bilder rütteln</strong></p><p></p><p>Zwei winzige Änderungen im Beispielcode und es geht, habs mal rot gekennzeichnet:</p><p></p><p>[CODE]</p><p><html></p><p><head></p><p></p><p><style></p><p>.shakeimage{</p><p>position:relative</p><p>}</p><p></style></p><p><script language="JavaScript1.2"></p><p></p><p>/*</p><p>Shake image script (onMouseover)-</p><p>© Dynamic Drive (www.dynamicdrive.com)</p><p>For full source code, usage terms, and 100's more DHTML scripts, visit http://dynamicdrive.com</p><p>*/</p><p></p><p>//configure shake degree (where larger # equals greater shake)</p><p>var rector=3</p><p></p><p>///////DONE EDITTING///////////</p><p>var stopit=0</p><p>var a=1</p><p></p><p>function init(which){</p><p>stopit=0</p><p>shake=which</p><p>shake.style.left=0</p><p>shake.style.top=0</p><p>[COLOR=Red]window.setTimeout("stoprattle(document.images[0])", 5000);[/COLOR]</p><p>}</p><p></p><p>function rattleimage(){</p><p>if ((!document.all&&!document.getElementById)||stopit==1)</p><p>return</p><p>if (a==1){</p><p>shake.style.top=parseInt(shake.style.top)+rector</p><p>}</p><p>else if (a==2){</p><p>shake.style.left=parseInt(shake.style.left)+rector</p><p>}</p><p>else if (a==3){</p><p>shake.style.top=parseInt(shake.style.top)-rector</p><p>}</p><p>else{</p><p>shake.style.left=parseInt(shake.style.left)-rector</p><p>}</p><p>if (a<4)</p><p>a++</p><p>else</p><p>a=1</p><p>setTimeout("rattleimage()",50)</p><p>}</p><p></p><p>function stoprattle(which){</p><p>stopit=1</p><p>which.style.left=0</p><p>which.style.top=0</p><p>}</p><p></p><p></script></p><p></p><p></head></p><p></p><p><body [COLOR=Red]onLoad="init(document.images[0]);rattleimage();"[/COLOR]></p><p></p><p><img src="man.gif" class="shakeimage"></p><p></p><p></body></p><p></html></p><p>[/CODE]</p></blockquote><p></p>
[QUOTE="cebito, post: 868201, member: 173078"] [b]AW: Bilder rütteln[/b] Zwei winzige Änderungen im Beispielcode und es geht, habs mal rot gekennzeichnet: [CODE] <html> <head> <style> .shakeimage{ position:relative } </style> <script language="JavaScript1.2"> /* Shake image script (onMouseover)- © Dynamic Drive (www.dynamicdrive.com) For full source code, usage terms, and 100's more DHTML scripts, visit http://dynamicdrive.com */ //configure shake degree (where larger # equals greater shake) var rector=3 ///////DONE EDITTING/////////// var stopit=0 var a=1 function init(which){ stopit=0 shake=which shake.style.left=0 shake.style.top=0 [COLOR=Red]window.setTimeout("stoprattle(document.images[0])", 5000);[/COLOR] } function rattleimage(){ if ((!document.all&&!document.getElementById)||stopit==1) return if (a==1){ shake.style.top=parseInt(shake.style.top)+rector } else if (a==2){ shake.style.left=parseInt(shake.style.left)+rector } else if (a==3){ shake.style.top=parseInt(shake.style.top)-rector } else{ shake.style.left=parseInt(shake.style.left)-rector } if (a<4) a++ else a=1 setTimeout("rattleimage()",50) } function stoprattle(which){ stopit=1 which.style.left=0 which.style.top=0 } </script> </head> <body [COLOR=Red]onLoad="init(document.images[0]);rattleimage();"[/COLOR]> <img src="man.gif" class="shakeimage"> </body> </html> [/CODE] [/QUOTE]
Bilder bitte
hier hochladen
und danach über das Bild-Icon (Direktlink vorher kopieren) platzieren.
Zitate einfügen…
Authentifizierung
Wenn ▲ = 7, ▼ = 3, ◇ = 2 und die Summe von ▲ und ▼ durch ◇ geteilt wird, was ist das Ergebnis?
Antworten
Start
Forum
Sonstiges
Webdesign, Webentwicklung & Programmierung
Webdesign: HTML/CSS, Responsive Design, Sass...
Bilder rütteln
Oben