Launch Bootstrap 4 Modal From WordPress Menu

Add .launch-contact-modal class to your WordPress menu item. This can be done from the admin interface Appearance > Menu.

Change #contactModal in the following jQuery to the ID of your Bootstrap 4 modal.

  // Adding Bootstrap Modal to WordPress Menu
  $('.launch-contact-modal').find('a').attr('data-toggle', 'modal');
  $('.launch-contact-modal').find('a').attr('data-target', '#contactModal');
Hello, I am Arun Basil Lal. Thank you for reading!

I am a WordPress product developer and creator of Image Attributes Pro. I am passionate about solving problems and travelling the world.

Divi WordPress Theme - My Review

Divi WordPress Theme
Divi is a WordPress theme that web designers do not want you to know. It comes with a drag-and-drop theme builder. You can build beautiful looking unique websites without touching a line of code. Just choose from one of the many pre-made layouts, or pick elements and arrange them any way you like.

Divi is every WordPress developer's wet dream. Surprise your clients with neat responsive websites and have fun building them.

Divi comes from Elegant Themes. If you enjoy building websites, you *need* an Elegant Themes membership. 87 beautiful themes and 5 plugins for the cost of less than a candy-bar each!

Note: I am an avid user of Divi myself and this is a honest review. I wouldn't recommend something that I do not personally find amazing.


  1. Ritesh Sirvastava says:

    Nice Post Sir It helps a lot to learn more.

  2. Jeff says:

    Worked Perfect Thanks!

  3. Yvette says:

    This helped me so much, super straightforward! Thank you!!

  4. Vanja says:

    Thank you so much! God bless you!

Leave a Reply

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