Disable text on input fields contact form 7 wordpress
Asked Answered
O

6

11

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

Ontine answered 28/8, 2014 at 2:53 Comment(4)
Do you have placeholder set on the form config?Shapely
I have tried using the placeholder but it doesn't work yet! :/Ontine
Did you try [text text-7 placeholder ""]? Or disabling other plugins/swapping themes?Shapely
I have tried with the placeholder on the form config onlyOntine
E
32

Use the word readonly for example

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

i tried this and it worked

Evaluate answered 14/11, 2015 at 15:50 Comment(0)
C
3

try this

[text domainname  readonly]

Its working perfectly

Chrysoprase answered 10/3, 2017 at 6:3 Comment(0)
M
1

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"]

Mediator answered 2/12, 2019 at 12:38 Comment(0)
H
0

Try this

[text text-346 placeholder "nombre completo"]

Hexaemeron answered 24/11, 2014 at 11:23 Comment(1)
This answer worked for me using Contact Form 7, version 5.8.5. Adding "placeholder" makes the text uneditable and disappear when the user starts typing something into the input field. Make sure that "placeholder" comes straight after the field name as in the example - putting it in the wrong position can disable it. Using "readonly" makes it so the user cannot type anything into the input field.Mathia
A
0
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 {
                    
                }
            });
Arabic answered 17/7, 2024 at 11:50 Comment(0)
C
-2

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]
Camfort answered 28/8, 2014 at 6:5 Comment(1)
I have tried wit this feature and the text on the field doesn't change :/Ontine

© 2022 - 2025 — McMap. All rights reserved.