Questions and discussion about developing processes and programming in PHP, JavaScript, web services & REST API.
Forum rules: Please search to see if a question has already asked before creating a new topic. Please don't post the same question in multiple forums.
By iacsvrn
#828605
Hello.

If I`m wirte to textarea some, and after two or three steps come to in field, I can edit, but can`t disable to delete text and enable only add it.

How I can create something like a textarea field where I can correspond with someone, but we can`t delete what we`ve already written there.
By marceloayllon
#830104
Hello iacsvrn,

You should use the getControl() function, in order to select the Dynaform control inner HTML element, and the proper way to disable it is using prop().

So, your code should look like this:

Code: Select all
function checkComplianceFor() { 
  if( $('#complianceType').getValue() == 0 ){ 
 	 $("#renewalFrequency").getControl().prop('disabled', true);
  } 
}

$('#complianceType').setOnchange(checkComplianceFor);
I hope you'll find this example useful.

Regards,

Get an instant solution to move emails to MBOX for[…]

Most Demanding OST to PST Converter

The most demanding OST to PST Converter is TrijaT[…]

Betvisa clone scripts are pre-built software solut[…]

A Bet365 Clone Script is essentially a ready-made […]