aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Help on conditionally disabling the fields Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Help on conditionally disabling the fields" Watch "Help on conditionally disabling the fields" New topic
Author

Help on conditionally disabling the fields

ms raaghu
Ranch Hand

Joined: Jul 10, 2009
Posts: 66
hi,
I have two radio button say
radio 1 and 2 respectively..
and a text field.. ..... on page load the radio 1 will be selected
so based on that condition textfield shld be disabled ?
please let me know how can i achieve this.. ?

i have written a function where on change the textfield will be disabled but when the page refreshed the disability
is gone for a toss...so please tell how dis can be done??
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60077
    
  65

ms raaghu wrote:how dis can be done??

dis? What is "dis"?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
ms raaghu
Ranch Hand

Joined: Jul 10, 2009
Posts: 66
Sorry "dis" refers to "THIS"
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
on window.onload look at what the radio button is set to and call your function that enables and disables.

Eric
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Help on conditionally disabling the fields
 
Similar Threads
validating textfield with +ve/-ve values using 2 radiobuttons
doubt in getParameter()
Auto Populate Combo Box upon Radio Selection
refreshing the page when radio button clicked
get disabled values from HttpServletRequest parameter