is there a way for the user to control images in javascript. For example like use the arrow keys to move a picture around the screen or click a picture with the mouse and drag it around the screen. If there is can someone explain to me how to do it.
thanks
is there a way to use the arrow keys or other keys to move or create images. i was also wondering what does the ! mark in javascripts do.
thanks
ps the script you gave me works perfectly for dragging the boxes thanks for it.
The ! mark means "does not" or "is not"
It's basically a negation sign I guess
In this example:
tempX = (!ns) ? event.clientX : e.pageX;
He creates a variable (tempX)
If ns is not True (not beign the ! mark), tempX will be event.clientX, otherwise, it'll be e.pageX
Which brings me to my own question:
wouldn't
tempX = (ns) ? e.pageX : event.clientX
do the same thing?
Oh yeah that makes sense thanks and sorry for the stupid question but does anyone know how to make an image move or create in image with keyboard commands?
Thanks