Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > cursor location on page load

Reply
Thread Tools

cursor location on page load

 
 
hev
Guest
Posts: n/a
 
      01-24-2005
I'm looking for html code that will allow me to place the cursor location on
page load to whatever text field I choose. Thanks.

-hev


 
Reply With Quote
 
 
 
 
Steve Greenaway
Guest
Posts: n/a
 
      01-24-2005
Kermit the Frog stuck a mic in hev's face, who said:
>I'm looking for html code that will allow me to place the cursor location on
>page load to whatever text field I choose. Thanks.


I can't really help you with that other than to say, 'check out
javascript'.

But please, please don't do it. I REALLY get annoyed when I'm halfway
through typing a web form, and the cursor suddenly shifts to a different
field while I'm typing my password.


--
- Steve
"I think a good friend would recommend CLR to all his friends."
 
Reply With Quote
 
 
 
 
nice.guy.nige
Guest
Posts: n/a
 
      01-24-2005
While the city slept, hev ((E-Mail Removed))
feverishly typed...

> I'm looking for html code that will allow me to place the cursor
> location on page load to whatever text field I choose. Thanks.


You can't do this with HTML, but you can with javascript:
http://www.html-faq.com/htmlforms/?entryfocus

Cheers,
Nige

--
Nigel Moss
http://www.nigenet.org.uk
Mail address not valid. http://www.velocityreviews.com/forums/(E-Mail Removed), take the DOG. out!
In the land of the blind, the one-eyed man is very, very busy!


 
Reply With Quote
 
Travis Newbury
Guest
Posts: n/a
 
      01-24-2005
Steve Greenaway wrote:
> Kermit the Frog stuck a mic in hev's face, who said:
> >I'm looking for html code that will allow me to place the cursor

location on
> >page load to whatever text field I choose. Thanks.

> I can't really help you with that other than to say, 'check out
> javascript'.
> But please, please don't do it. I REALLY get annoyed when I'm

halfway
> through typing a web form, and the cursor suddenly shifts to a

different
> field while I'm typing my password.


If it happens on pageload, why should it shift when you are halfway
through entering data in the form?

--
-=tn=-

 
Reply With Quote
 
nice.guy.nige
Guest
Posts: n/a
 
      01-24-2005
While the city slept, Steve Greenaway ((E-Mail Removed)) feverishly
typed...

[setting form field focus]
> But please, please don't do it. I REALLY get annoyed when I'm halfway
> through typing a web form, and the cursor suddenly shifts to a
> different field while I'm typing my password.


The link I gave to the OP (http://www.html-faq.com/htmlforms/?entryfocus)
overcomes that Major Annoyance by only setting the focus if the form isn't
already in use.

Cheers,
Nige

--
Nigel Moss
http://www.nigenet.org.uk
Mail address not valid. (E-Mail Removed), take the DOG. out!
In the land of the blind, the one-eyed man is very, very busy!


 
Reply With Quote
 
nice.guy.nige
Guest
Posts: n/a
 
      01-24-2005
While the city slept, Travis Newbury ((E-Mail Removed)) feverishly
typed...

> Steve Greenaway wrote:
>> Kermit the Frog stuck a mic in hev's face, who said:
>>> I'm looking for html code that will allow me to place the cursor
>>> location on page load to whatever text field I choose. Thanks.

>> I can't really help you with that other than to say, 'check out
>> javascript'.
>> But please, please don't do it. I REALLY get annoyed when I'm
>> halfway through typing a web form, and the cursor suddenly shifts to
>> a different field while I'm typing my password.

>
> If it happens on pageload, why should it shift when you are halfway
> through entering data in the form?


Because the form may be displayed before the onload event fires (eg. images
are still loading, etc) in which time the user can be typing merrily away in
the form. IIRC Google Groups Advanced Search form can be a pain for that. My
suggestion uses javascript to only set the focus if the form is not yet in
use. It ain't perfect, but then, neither am I...

Cheers,
Nige

--
Nigel Moss
http://www.nigenet.org.uk
Mail address not valid. (E-Mail Removed), take the DOG. out!
In the land of the blind, the one-eyed man is very, very busy!


 
Reply With Quote
 
Richard
Guest
Posts: n/a
 
      01-24-2005
On 24 Jan 2005 17:45:30 GMT Steve Greenaway wrote:

> Kermit the Frog stuck a mic in hev's face, who said:
>>I'm looking for html code that will allow me to place the cursor
>>location on
>>page load to whatever text field I choose. Thanks.


> I can't really help you with that other than to say, 'check out
> javascript'.


> But please, please don't do it. I REALLY get annoyed when I'm halfway
> through typing a web form, and the cursor suddenly shifts to a
> different
> field while I'm typing my password.


He said "onload", not after the page has loaded fully.
So that your mouse is positioned on a certain form before you do anything.
Sure it's annoying. Just as are all those cute flashing banner ads, hit the
target ads and such.
But at least I can move the mouse.


 
Reply With Quote
 
hev
Guest
Posts: n/a
 
      01-24-2005
"nice.guy.nige" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> While the city slept, hev ((E-Mail Removed))
> feverishly typed...
>
>> I'm looking for html code that will allow me to place the cursor
>> location on page load to whatever text field I choose. Thanks.

>
> You can't do this with HTML, but you can with javascript:
> http://www.html-faq.com/htmlforms/?entryfocus
>
> Cheers,
> Nige
>
> --
> Nigel Moss
> http://www.nigenet.org.uk



Thanks Nigel

That's exactly what I was looking for. Now my personal startup page brings
the focus to my google search field right off the bat! I'm happy. Thanks.

-hev


 
Reply With Quote
 
Hywel Jenkins
Guest
Posts: n/a
 
      01-24-2005
In article <(E-Mail Removed)>, Anonymous@127.001 says...
> On 24 Jan 2005 17:45:30 GMT Steve Greenaway wrote:
>
> > Kermit the Frog stuck a mic in hev's face, who said:
> >>I'm looking for html code that will allow me to place the cursor
> >>location on
> >>page load to whatever text field I choose. Thanks.

>
> > I can't really help you with that other than to say, 'check out
> > javascript'.

>
> > But please, please don't do it. I REALLY get annoyed when I'm halfway
> > through typing a web form, and the cursor suddenly shifts to a
> > different
> > field while I'm typing my password.

>
> He said "onload", not after the page has loaded fully.


The onload event fires *after* the page has loaded fully, not during.

--
Hywel http://kibo.org.uk/
I do not eat quiche.
 
Reply With Quote
 
JDS
Guest
Posts: n/a
 
      01-24-2005
On Mon, 24 Jan 2005 17:11:22 +0000, hev wrote:

> I'm looking for html code that will allow me to place the cursor location
> on page load to whatever text field I choose. Thanks.
>
> -hev


I see you got your answer. Be careful in implementing something like
this, though. For example, focusing the cursor on a form that is far down
the page will cause the page to scroll all the way down all of a sudden.
It has a high potential to become an annoying nuisance.

--
JDS | (E-Mail Removed)
| http://www.newtnotes.com

 
Reply With Quote
 
 
 
Reply

Thread Tools

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to tell if cursor is sqlite.Cursor or psycopg2.Cursor dmaziuk Python 3 01-25-2011 04:52 AM
Location, location, location =?Utf-8?B?VHJhY2V5?= Wireless Networking 2 02-17-2007 08:37 PM
Declare Cursor error while implementing SCROLL CURSOR invy C Programming 4 12-28-2006 02:35 PM
Changing DEFAULT cursor to WAIT cursor in ASP =?Utf-8?B?VG9tYXMgS2VwaWM=?= ASP .Net 1 04-05-2005 07:42 PM
Cursor location on page Kevin Davis Java 0 07-18-2003 09:00 PM



Advertisments