User not logged in - login - register
Home Calendar Books School Tool Photo Gallery Message Boards Users Statistics Advertise Site Info
go to bottom | |
 Message Boards » » Our www4 webspace Page [1]  
sccrdude1
All American
611 Posts
user info
edit post

Does it support javascript?

1/19/2006 12:54:05 AM

dFshadow
All American
9507 Posts
user info
edit post

of course

1/19/2006 1:05:03 AM

sccrdude1
All American
611 Posts
user info
edit post

that's what I was afraid of.....now to figure out why it isn't working

1/19/2006 1:06:06 AM

dFshadow
All American
9507 Posts
user info
edit post

post a link

1/19/2006 1:06:56 AM

sccrdude1
All American
611 Posts
user info
edit post

http://www4.ncsu.edu/~cdwinste/hbpics.html

Trying to get some pictures I took to show up as a slideshow sorta thing, but only the buttons show up.

my code is.....

<script language="JavaScript"><!--
which_image_loaded = 0;
NUMBER_OF_IMAGES = 30;

ImageNames = new Object();
ImageNames.length = NUMBER_OF_IMAGES - 1;

for (counter = 0; counter < NUMBER_OF_IMAGES; counter++){
file_number = counter + 1;
filename = ("hb/" + file_number + ".jpg");
ImageNames[counter] = filename;
}

function changeImage(direction) {
which_image_loaded += direction;
if (which_image_loaded < 0)
which_image_loaded = NUMBER_OF_IMAGES - 1;
if (which_image_loaded == NUMBER_OF_IMAGES)
which_image_loaded = 0;
if (document.images)
document.myimage.src = ImageNames[which_image_loaded];
}
//--></script>

<form>
<input type="button" value="<<" onClick='changeImage(-1);'>
<input type="button" value=">>" onClick='changeImage(1);'>
</form>

with the pictures being in a different folder and each picture's name is a number 1-30

[Edited on January 19, 2006 at 1:10 AM. Reason : added the button code]

1/19/2006 1:09:08 AM

sccrdude1
All American
611 Posts
user info
edit post

Nevermind....I got it, I forgot to put in the tag to actually show the picture

1/19/2006 1:12:00 AM

moron
All American
34024 Posts
user info
edit post

Could it be that counter is an int, and you can't concatenate it as an int, unless you do int.toString()?

[Edited on January 19, 2006 at 1:13 AM. Reason : file_number I mean... it is set to counter]

I guess not...

[Edited on January 19, 2006 at 1:14 AM. Reason : ]

1/19/2006 1:13:20 AM

sccrdude1
All American
611 Posts
user info
edit post

thanks though

1/19/2006 1:22:28 AM

 Message Boards » Tech Talk » Our www4 webspace Page [1]  
go to top | |
Admin Options : move topic | lock topic

© 2024 by The Wolf Web - All Rights Reserved.
The material located at this site is not endorsed, sponsored or provided by or on behalf of North Carolina State University.
Powered by CrazyWeb v2.38 - our disclaimer.