WordPress: How to add a show text link in Contact Form 7

Do you use WordPress famous form plugin called Contact Form 7 and want to add a show link to display a field? Yes you can with Contact Form 7 due to it’s open source type of plugin. It’s easy and flexible.

This is how you do it

  1. Create new form in Contact Form 7
  2. Once form is set, at the top of the form code, add this script:
<script language="JavaScript">
   function showText(id)
    {
        document.getElementById(id).style.display = "block";
    }
</script>
Screen-Shot-2021-08-18-at-9.54.58-AM-1024x635 WordPress: How to add a show text link in Contact Form 7

3. Then add the link that you want the user to click to show the text:

<a name="16:10" onclick="showText('text1')" href="javascript:void(0);" style="color: black"><strong>Add Attorney/Paralegal Email</strong></a>
Screen-Shot-2021-08-18-at-9.56.17-AM-1024x220 WordPress: How to add a show text link in Contact Form 7

4. Hit “SAVE” and viola!

The advantage of Contact Form 7 is that you are able to implement code within the from and create wonders. Leave a comment below for reactions or for any questions, contact us.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.