Your HostICan Community  


Go Back   Your HostICan Community > Programming & Design > Javascript / Java Applets

Javascript / Java Applets Are you a JavaScript guy? Do you need help with JavaScript? This is the place to talk about anything related to Java.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-31-2009, 02:30 PM
ultima ultima is offline
Junior Member
 
Join Date: Aug 2009
Posts: 2
Default select/deselect input box for a site of my hosting.

I'm trying to implement an idea for a site of my hosting, but I need help. Can someone show a small example of how by clicking on the input box is highlighted and clicking for a second time is deselect (and change the text)?
Reply With Quote
  #2  
Old 08-31-2009, 03:32 PM
rasho's Avatar
rasho rasho is offline
Junior Member
 
Join Date: Jan 2009
Posts: 6
Default Re: select/deselect input box for a site of my hosting.

With this line you can do selection of text box:
HTML Code:
onClick="doSelect(this);"
The folowing code can does deselect:
HTML Code:
var firstSelection = true;
function doSelect(el){
if( firstSelection ){
el.select();
firstSelection = false;
}
}
Reply With Quote
Reply

Tags
box, hosting, input, select or deselect, site

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 03:31 PM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.

Copyright © 2003 - 2008 HostICan. All Rights Reserved.