![]() |
![]() |
![]() ![]()
Post
#1
|
|
Grupa: Zarejestrowani Postów: 87 Pomógł: 3 Dołączył: 15.08.2009 Ostrzeżenie: (0%) ![]() ![]() |
Witam, chcę zrobić skrypt który by pokazywał tekst z Array na divie po kliknięciu obrazka > Dawało do następnego a po < cofało do poprzedniego..
mam takie coś: Lecz to nie działa, chciał bym to też zrobić żeby to się wyświetlało w divie jakimś np. pole.. Proszę o pomoc! |
|
|
![]() |
![]()
Post
#2
|
|
Grupa: Zarejestrowani Postów: 87 Pomógł: 3 Dołączył: 15.08.2009 Ostrzeżenie: (0%) ![]() ![]() |
Tutaj dałem tylko przykład, a tak mam na prawde:
Kod <html lang="POL"> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <title> CS-Rewolucja.pl - Sklep </title> <link rel="stylesheet" type="text/css" href="style.css" /> <meta name="robots" content="noodp, noydir, index, follow" /> <meta name="googlebot" content="noodp, noydir, index, follow" /> <meta name="audience" content="all" /> <meta name="language" content="pl" /> <meta name="resource-type" content="document" /> <meta name="copyright" content="cs-rewolucja.pl" /> <meta name="revisit-after" content="1" /> <meta name="distribution" content="global" /> <meta name="location" content="Poland" /> <script language="javascript"> function Sol(){ var tekst = Array("item1", "item2", "item3", "item4", "item5" ); var linki = Array("poka_1", "poka_2", "poka_3", "poka_4", "poka_5" ); var ktore = 0; function Przewin(ok) { if(ok == 0) { ktore+=1; document.getElementById('ss').innerHTML = tekst[ktore]; } if(ok == 1) { ktore-=1; document.getElementById('ss').innerHTML = tekst[ktore]; } }} </script> </head> <body onload="Sol();"> <center><a href="http://cs-rewolucja.pl" border="0"><img src="images/logo.png"></a></center> <div id="bg"> <div id="ss"></div> </div> <div id="lewo"> <a onclick="Przewin(1);"><img border="0" src="images/lewo.png"/></a> </div> <div id="prawo"> <a onclick="Przewin(0);"><img border="0" src="images/prawo.png"/></a> </div> </body> </html> w <A> nie ma java script:void(0); bo jak dałem to mi pokazywało błąd że nie ma takiej strony ;./ Ten post edytował zielu001 8.09.2010, 18:09:43 |
|
|
![]() ![]() |
![]() |
Aktualny czas: 5.10.2025 - 03:32 |