Page 1 of 1

Arrow key navigation issue

Posted: Tue Dec 16, 2003 7:04 am
by showme
I am pretty new to PHP and he looked in many places for an idea on how to do this but have failed. Here is what I would like to do.

I would like to use the arrow keys to navigate a game grid. for expamly I have a grid with X and Y axis and the person is at $x=5 and $Y=5 and then click the Up arrow key and it will read my database to see the data for $x=4 and $y=5

I know that PHP is all sever side but I am sure there is a way to do thiw with Java script. I can get it to display text now but I am not a Java script expert either . Any help would be great. This is a key part to getting my game working for beta testing

Posted: Tue Dec 16, 2003 8:40 am
by malcolmboston
do it in flash, pretty sure it would be possible in PHP but extermely complex and unless you are a godly scripter then probably beyond your (and my) scope, flash is extremely simple to do it with

also if you have macromedia suite there are tutorials about this on flash MX

thanks

Posted: Tue Dec 16, 2003 8:52 am
by showme
This will be in an online game and do not see how I could do it in flash with out major changes to the way the game is being set up. I have seen this done in ASP sites and it worksa well and I think it could be done with Java script but I just don't know where to start with that idea

Posted: Tue Dec 16, 2003 8:54 am
by malcolmboston
i have never done anything like that in JS so i cannot help you mate
sorry

Posted: Tue Dec 16, 2003 11:21 am
by scorphus
showme, can you please give us some example, some of those ASP sites you said above? Then we can take a look to it and try to find something out.

Cheers,
Scorphus.

Posted: Tue Dec 16, 2003 11:27 am
by microthick
This link might be a little help. Shows ways of using arrow keys to navigate from one text box to another. You might be able to adapt.

Different code samples for VBScript and JavaScript.

http://dbforums.com/arch/195/2002/9/510498