473,289 Members | 1,848 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,289 software developers and data experts.

Safari Issue

1
I have a strange issue with safari.
My intention was to capture for the keystroke and increment and decrement a particular test box value by 1 or -1.The following is my code.

Expand|Select|Wrap|Line Numbers
  1.     var y=x.value
  2.     var VK_UP = 38;
  3.     var VK_DOWN = 40;
  4.     switch (e.keyCode){
  5.         case VK_UP : {    y++;                        
  6.                      break}
  7.         case VK_DOWN : {y--;
  8.                         break}
  9.         default : {return};
  10.     }
  11.     x.value=y
  12. }
  13.  
This works for both IE and firefox. But its working for Safari in MAC machine in a strange way. The value i was getting after a key press is either +/-2 rather than +/-1.Can anyone help to solve this issue?

Thanks
Lal
Nov 15 '07 #1
1 971
Dasty
101 Expert 100+
Can you show us how do you attach the event handler?
Nov 15 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

14
by: DU | last post by:
According to a recent post, it seems that Konqueror 3.1+ and Safari 1.1 support CSS3 opacity style property under a proprietary name: "Support for the CSS3 opacity (using -khtml-opacity)...
5
by: sanj | last post by:
Hi all, My site is located at: http://www.eastdayspa.com/index.html I have use these main styles /* main styles */
4
by: Nitronic | last post by:
I got this javascript code below and each time i got to a safari browser it thinks its netscpe any ideas. But i threw in Safari code but it doesn't work. var browserName=navigator.appName; //...
21
by: Doug Lerner | last post by:
I'm working on a client/server app that seems to work fine in OS Firefox and Windows IE and Firefox. However, in OS X Safari, although the UI/communications themselves work fine, if the...
4
by: metoikos | last post by:
I've scoured the web (clumsily, I'm sure) for information on the difficulties I am having, checked my markup in validators, and had a friend with more CSS clue look over it, but I haven't had any...
12
by: effendi | last post by:
I wrote the following function and tested it in MSIE, Firefox and Mac Safari, Works in all but the Safari. What can I do to rectify this? function processBackground(){ for (n=1;n<11;n++) { ...
16
by: Edward | last post by:
Hi All, I am having huge problems with a very simple dotnet framework web page (www.gbab.net/ztest3.aspx) , it does NOT render correctly under Apple's Safari. The DIV's do not align amd float as...
5
by: Liam | last post by:
Hi all. New to the group and new to using Safari (for work). I noticed while coding a module at work that the sort() works quite differently in Safari than it does in FireFox and IE. My issue...
7
by: David Stone | last post by:
Run into something recently that has left me a little puzzled. According to the examples in section 13.6.1 of html 4.01... <http://www.w3.org/TR/html401/struct/objects.html#h-13.6.1.1> I...
15
by: GinnTech | last post by:
I have a site that works perfectly in IE6 IE7 FF2 FF3 but not in the latest Safari. Here is the issue. I am attempting to call functions within a flash object. When trying to attempt to...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: marcoviolo | last post by:
Dear all, I would like to implement on my worksheet an vlookup dynamic , that consider a change of pivot excel via win32com, from an external excel (without open it) and save the new file into a...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.