Diegolops
Diegolops

Reputation: 113

Disable text on input fields contact form 7 wordpress

I want to disable or erase the text of my input fields from my contact form.

Specially on the fields that appears text like "Full name", "Email Address" and "Your message will be here"

I am using Contact Form 7 of Wordpress and I configured spanish lenguage as default but it still in english this text.

Here is the link: http://crepali.com.mx/contacto/

How can I translate it or disable?

Thanks

Upvotes: 11

Views: 56514

Answers (6)

Maulik patel
Maulik patel

Reputation: 2436

jQuery('.messagedata').keydown(function(event) {
                if (event.ctrlKey==true && (event.which == '118' || event.which == '86')) {
                    //alert('thou. shalt. not. PASTE!');
                    event.preventDefault();
                 }
            });
            jQuery(document).on('keypress', '.messagedata', function (e) {
                const pressedKey = e.key;
                let pressedKeyCode = e.charCode;
                
                
                if ((pressedKeyCode >= 33 && pressedKeyCode <= 47) || 
                    (pressedKeyCode >= 58 && pressedKeyCode <= 64) || 
                    (pressedKeyCode >= 91 && pressedKeyCode <= 96) || 
                    (pressedKeyCode >= 123 && pressedKeyCode <= 126) ) 
                {
                    e.preventDefault();
                
                    
                }
                else {
                    
                }
            });

Upvotes: 0

Aslam Khan
Aslam Khan

Reputation: 378

If you want to make a field read-only, set the readonly option in the form-tag like this:

  1. ****strong textTry this

[text* your-name readonly class:required "Write your text here"]

Upvotes: 1

Pradeep rajendiren
Pradeep rajendiren

Reputation: 63

try this

[text domainname  readonly]

Its working perfectly

Upvotes: 3

Shuhad zaman
Shuhad zaman

Reputation: 3390

Use the word readonly for example

[text text-859 readonly "1 Week Trial"] 

i tried this and it worked

Upvotes: 32

Kushal Shah
Kushal Shah

Reputation: 447

Try this

[text text-346 placeholder "nombre completo"]

Upvotes: 0

Sandeep Kumar
Sandeep Kumar

Reputation: 617

In wp-admin you have seen Contact Menu form here you create the contact form

Full Name is the placholder which you are seeing.

your code in the contact form 7 like following

[text text-346 placeholder "full name"]

Kindly remove the "placholder full name" text form the field

 [text text-346]

Upvotes: -2

Related Questions