HighDots Forums  

Prompt() in Safari

Javascript JavaScript language (comp.lang.javascript)


Discuss Prompt() in Safari in the Javascript forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Greg Taylor
 
Posts: n/a

Default Prompt() in Safari - 01-03-2008 , 01:23 PM






Greetings,

I was wondering if there was a way to make prompt() calls in Safari
show a single-line input box instead of the default multi-line prompt
that it currently does.

It seems like most other browsers just provide a single-line prompt
text box, meaning that the user hitting ENTER is the same as them
hitting the "Ok" button. In Safari (where the prompt() calls result in
a multi-line input box), hitting ENTER is interpreted as a new line
return.

This is just a matter of consistency. Some of my less computer savvy
users have been irritated by this and my Googling hasn't turned up a
way to make the prompts single line.

Reply With Quote
  #2  
Old   
David Mark
 
Posts: n/a

Default Re: Prompt() in Safari - 01-03-2008 , 07:59 PM






On Jan 3, 2:23*pm, Greg Taylor <squishywaf... (AT) gmail (DOT) com> wrote:
Quote:
Greetings,

I was wondering if there was a way to make prompt() calls in Safari
show a single-line input box instead of the default multi-line prompt
that it currently does.
No. You are stuck with whatever the browser provides.

Quote:
It seems like most other browsers just provide a single-line prompt
text box, meaning that the user hitting ENTER is the same as them
hitting the "Ok" button. In Safari (where the prompt() calls result in
a multi-line input box), hitting ENTER is interpreted as a new line
return.
That is irritating. Best not to use prompt at all though. Same for
alert. Some aggressive popup blockers intercept them.


Reply With Quote
  #3  
Old   
RobG
 
Posts: n/a

Default Re: Prompt() in Safari - 01-03-2008 , 08:45 PM



On Jan 4, 5:23*am, Greg Taylor <squishywaf... (AT) gmail (DOT) com> wrote:
Quote:
Greetings,

I was wondering if there was a way to make prompt() calls in Safari
show a single-line input box instead of the default multi-line prompt
that it currently does.
No, but you can do an imitation of a prompt using script and DOM
elements.


Quote:
It seems like most other browsers just provide a single-line prompt
text box, meaning that the user hitting ENTER is the same as them
hitting the "Ok" button. In Safari (where the prompt() calls result in
a multi-line input box), hitting ENTER is interpreted as a new line
return.
Not in Safari 3.0.4, it behaves as other browsers do, which is
annoying as it displays a multi-line field but when you press the
return or enter keys to enter another line, it submits.


Quote:
This is just a matter of consistency. Some of my less computer savvy
users have been irritated by this and my Googling hasn't turned up a
way to make the prompts single line.
Tell them to change browsers or update to Safari 3.


--
Rob


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.