473,385 Members | 1,168 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,385 software developers and data experts.

fire fox on mac and file input

ja
hi,

i need to assign onclick function to file inupt, in fire fox on windows
function is executing just after click, but on mac it seems to be execut
after file browse window is closed (in safari it works ok).

did any one meet the same problem? any work around?

greets
wojtek
Nov 30 '06 #1
5 1555
ja wrote:
hi,

i need to assign onclick function to file inupt, in fire fox on windows
function is executing just after click, but on mac it seems to be execut
after file browse window is closed (in safari it works ok).

did any one meet the same problem?
You have described a particular behaviour, whether it is a problem or
not depends on your point of view. My version of Firefox on OS X
behaves the same as yours - I can't comment on whether it's a problem
without knowing more about why I should think so.

For example:

<input type="file" onclick="alert(this.value);">

May work better if the browse dialog comes up first.

any work around?
You mean, can you force the click event to be triggered before the
browse dialog is activated rather than after? No, not that I know of
(OK, the trivial response is to modify the browser source code, but
that is not useful advice for most people).
--
Fred

Nov 30 '06 #2
ja
You mean, can you force the click event to be triggered before the
browse dialog is activated rather than after? No, not that I know of
(OK, the trivial response is to modify the browser source code, but
that is not useful advice for most people).
--
Fred
thanks,

i have input file on div with is hidding and showing when user cilck some
element. It's something like this

<img onclick="show('divWithInput'); delyHide =
setTimeout(hide(''divWithInput''), 1000);" >

and in input
<input type="file" onclick="clearTimeout(delyHide);">

so, ther's is no way to get this working in ff on mac. let it be, i'll
change onclick with onmouseover it wont be exactly what i need, but will be
working :) i hope

BTW
shouldn't it works like this:
<input type="file" onclick="clearTimeout(delyHide);"
onchange="alert(this.value);">

wojtek
Nov 30 '06 #3
ASM
ja a écrit :
>
i need to assign onclick function to file inupt,
I don't unterdstand somebody has to fire by JS a file input.
in fire fox on windows
function is executing just after click, but on mac it seems to be execut
after file browse window is closed (in safari it works ok).
Did you try "onchange".
did any one meet the same problem? any work around?
--
Stephane Moriaux et son moins vieux Mac déjà dépassé
Stephane Moriaux and his less old Mac already out of date
Nov 30 '06 #4
ASM
ja a écrit :
It's something like this

<img onclick="show('divWithInput'); delyHide =
setTimeout(hide(''divWithInput''), 1000);" >

and in input
<input type="file" onclick="clearTimeout(delyHide);">
Isn't it too late ? (1 second is not a very long delay)

this here works :

<input type="file" onmousedown="clearTimeout(delyHide);">

--
Stephane Moriaux et son moins vieux Mac déjà dépassé
Stephane Moriaux and his less old Mac already out of date
Nov 30 '06 #5
ja
>
Isn't it too late ? (1 second is not a very long delay)

this here works :

<input type="file" onmousedown="clearTimeout(delyHide);">

--
Stephane Moriaux et son moins vieux Mac déjà dépassé
Stephane Moriaux and his less old Mac already out of date
1 second, it was only example :)
thanks, i complety forgot about onmousedown...

wojtek
Nov 30 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Epetruk | last post by:
Hi, I'm trying to design a simple web form, but I cannot get the code in the btnSubmit_ServerClick event to fire. What am I doing wrong? Here's the codebehind: using System; using...
0
by: Raven Jones | last post by:
Heya all, I'm working on a web-based application (using ASP.NET and C# on .NET 1.1.4322, supporting only IE6 for Windows) that allows for file uploads. Screen real estate is at a premium, so I...
2
by: Hoss | last post by:
Hi guys, The framework of my page is an aspx page with a header and a footer. The header is a menu system and depending on what you select there different ascx pages are loaded into the middle...
4
by: sowencheung | last post by:
Hi, all The scenario is like this: I have a master page, contains two user controls, one is a search control, another is a login control. The server-side <form> is in the master page,...
3
by: rfinch | last post by:
I'm trying to pass two values from client script (Javascript) to the code-behind for a page using three hidden fields - two to hold the values and a third to fire the ValueChanged event. I have...
17
by: Eric | last post by:
I'm new to JavaScript and I wrote this code to play with. Oddly, if I enter text in a box and then press the button, I only get the onChange event for the text box and not the button's onclick...
8
by: -Karl | last post by:
Snippet: http://www.nomorepasting.com/getpaste.php?pasteid=1020&seen=true&numbered=on&langoverride=asp Line 37 is where I am having the problem. I can't get the onclick event to fire off. Yet...
3
scubak1w1
by: scubak1w1 | last post by:
Hello, I posted this in the HTML forum, but it was suggested I post it over here as well by a moderator. I have a form that will not 'fire' in non-IE browsers?? I have poked and poked at the code...
6
by: GarryJones | last post by:
This is driving me simply crazy ... this simple (?) code works in Msie but not Firefox. function checkform () { if (document.regfrms.cgbx.itm1.checked == false &&...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.