...

View Full Version : backspace in form field



miglet
01-26-2005, 02:50 AM
yo

im wondering if anyone knows a solution that will make a backspace button (javascript onscreen, not the physical keyboard!), do its job in a form field - that will also take into account where the cursor is.

I know you can do it so the value=str.lenth-1 type deal, but that just removes the last character

If anybody has a fast/easy solution - or a premade bigger one, let me know!

jaywhy13
01-26-2005, 01:34 PM
that my frnd is gonna be much more complexed than it sounds... cause thats gonna include finding the cursor position.... textRange and stuff like that. I'm placing a link so you can have a look at the code.

The code... is to insert a caret into a textarea where the cursor is.... enjoy!

jaywhy13
01-26-2005, 01:37 PM
that my frnd is gonna be much more complexed than it sounds... cause thats gonna include finding the cursor position.... textRange and stuff like that. I'm placing a link so you can have a look at the code.

The code... is to insert a caret into a textarea where the cursor is.... enjoy!
Inserting Carets (http://www.webxpertz.net/forums/showthread.php?threadid=14947) :o

miglet
01-27-2005, 05:07 PM
i know about finding the position, but how would i use that to remove the character infront of the cursor?

can i put everything before the cursor in 1 string - then do a -1 value, and then re-combine the strings.. or what?

im lost :/



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum