Validating Fields in JavaScript
Copy link to clipboard
Copied
Hi,
We are trying to hide the text while entering into the text field and show the text after submitting the form. We need to know where we need to add this code
we used the below code
var a=this.getField("cityname") ;
var aValue="";
this.getField("cityname").onkeyup = function() {aaa()};
function aaa()
{
var inputvalue=a.value.substring(a.value.length-1);
if(a.value.length<=15)
aValue+="*";
else
aValue+=inputvalue;
a.value=aValue;
}
Copy link to clipboard
Copied
This script will overwrite any input made in the "cityname" field, instead of hiding it.
This is not part of the ECMAScript language:
this.getField("cityname").onkeyup
Acrobate du PDF, InDesigner et Photoshopographe
Copy link to clipboard
Copied
@JR Boulay We want to hide it while entering the text after submit we want to see the text. Can you help us with the coding
Copy link to clipboard
Copied
I guess you should use a text field with the "password" option enabled, but...
For obvious security reasons the value of such a field is not exported or saved with the other data.
So before sending the form the script should remove the "password" option from the field concerned, or duplicate its value in another (hidden) field.
Can you share your document or a rougth?
Acrobate du PDF, InDesigner et Photoshopographe
Copy link to clipboard
Copied
I attached form below
Copy link to clipboard
Copied
I have did this but text not exported
Copy link to clipboard
Copied
Are you serious?
😉
Acrobate du PDF, InDesigner et Photoshopographe
Copy link to clipboard
Copied
No Issue sir,
Password : Rise@123
I can make up the hours over the rest of the week, if that would help. Please let me know at your earliest convenience.
Thank you,
Manikanta

