הוסטס - פורום אחסון האתרים הגדול בישראל

הוסטס - פורום אחסון האתרים הגדול בישראל (https://hosts.co.il/forums/index.php)
-   פורום תיכנות (https://hosts.co.il/forums/forumdisplay.php?f=14)
-   -   פונצקיה בjavascript של הרצת קבצי טקסט (https://hosts.co.il/forums/showthread.php?t=8210)

יהודה 04-12-05 23:54

פונצקיה בjavascript של הרצת קבצי טקסט
 
למישהו יש?

1host 05-12-05 02:35

תסביר לי יותר בפירוט מה אתה מנסה להשיג...
כמו-כן, אם יש לך איזה דוגמא של משהו שעשית עד כה, או הצלחת חלק ונתקעת...
אז תדביק כאן או תן קישור או משהו.

יהודה 05-12-05 14:11

אני צריך פונקציה במקום אימג' בשביל שאני אוכל להריץ תמונות במקום תמונות.
הנה הקוד שעשיתי:
<html dir="rtl">

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1255">
<title>אנימציה</title>
<script>
var picindex=0;
var x;

one= new Image();
one.src = "http://img470.imageshack.us/img470/8022/fda3pvuelicompcopy2ue.gif"
two= new Image();
two.src = "http://img190.imageshack.us/img190/4421/champion182yt.jpg"
three= new Image ();
three.src= "http://img235.imageshack.us/img235/2157/liverpoolbackground6oi.jpg"

pic = new Array();

pic[0]=one.src;
pic[1]=two.src;
pic[2]=three.src;

function animation()
{
document. images ['clasic'].src= pic[picindex];
picindex=picindex+1;
if( picindex>2) picindex=0;
}
function intanimation()
{
x=setInterval ('animation();', 1000);
}
</script>
</head>

<body onload="intanimation();">
<img name="clasic" src="fda3pvuelicompcopy2ue.gif" width="142" height="180">
</body>
</html>
זה הקוט

YaronZ 05-12-05 15:48

ציטוט:

<html dir="rtl">

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1255">
<title>אנימציה</title>
<script>
var picindex=0;
var x;

one= new Image();
one.src = "http://img470.imageshack.us/img470/8022/fda3pvuelicompcopy2ue.gif"
two= new Image();
two.src = "http://img190.imageshack.us/img190/4421/champion182yt.jpg"
three= new Image ();
three.src= "http://img235.imageshack.us/img235/2157/liverpoolbackground6oi.jpg"

pic = new Array();

pic[0]=one.src;
pic[1]=two.src;
pic[2]=three.src;

function animation()
{
document. images ['clasic'].src= pic[picindex];
picindex=picindex+1;
if( picindex>2) picindex=0;
}
function intanimation()
{
x=setInterval ('animation();', 1000);
}
</script>
</head>

<body onload="intanimation();">
<img name="clasic" src="http://img470.imageshack.us/img470/8022/fda3pvuelicompcopy2ue.gif" width="142" height="180">
</body>
</html>
קח קוד מתאים.

Espire 05-12-05 17:34

-- נערך

הוא לא ביקש, אז אל תציע.


כל הזמנים הם GMT +2. הזמן כעת הוא 03:50.

מופעל באמצעות VBulletin גרסה 3.8.6
כל הזכויות שמורות ©
כל הזכויות שמורות לסולל יבוא ורשתות (1997) בע"מ