{"id":288,"date":"2018-11-24T13:59:18","date_gmt":"2018-11-24T13:59:18","guid":{"rendered":"http:\/\/help.unitedover.com\/digits\/?post_type=manual_kb&#038;p=288"},"modified":"2023-07-04T09:42:28","modified_gmt":"2023-07-04T09:42:28","slug":"how-to-trigger-modal-from-a-custom-button","status":"publish","type":"manual_kb","link":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/","title":{"rendered":"How To Trigger Modal From A Custom Button"},"content":{"rendered":"<p>Opening login\/signup page from the custom button is an easy task, you just need to link the button to our page <code>http:\/\/<em>www.yourwebsiteurl.com<\/em>\/?login=true<\/code><\/p>\n<p>Even triggering our modal from your custom button is an easy task.<br \/>\nJust <strong>assign<\/strong> <code>digits-login-modal<\/code> as the <strong>class<\/strong> for that button<\/p>\n<p>If you&#8217;re trying to trigger some specific page, then you also need to <strong>define type<\/strong> alongside with class<\/p>\n<p><strong><em>Registration<\/em><\/strong>: type=&#8221;2&#8243;<br \/>\n<strong><em>Forgot Password<\/em><\/strong>: type=&#8221;3&#8243;<br \/>\n<strong><em>Only Login<\/em><\/strong>: type=&#8221;4&#8243;<\/p>\n<p>For example:\u00a0<code>class=\"digits-login-modal\" type=\"2\"<\/code> for registration modal<\/p>\n<h4><\/h4>\n<h4><strong>Direct Links<\/strong><\/h4>\n<p><strong>Login\/Registration: <\/strong><span style=\"color: #ff0000\">yourwebsite.com<\/span>\/?login=true<strong><br \/>\nRegistration: <\/strong><span style=\"color: #ff0000\">yourwebsite.com<\/span>\/?login=true&amp;type=register<br \/>\n<strong>Forgot Password:<\/strong> <span style=\"color: #ff0000\">yourwebsite.com<\/span>\/?login=true&amp;type=forgot-password<br \/>\n<strong>Only Login:<\/strong> <span style=\"color: #ff0000\">yourwebsite.com<\/span>\/?login=true&amp;type=login<\/p>\n<h2>Builder<\/h2>\n<p>The above-mentioned steps even work with the builder once you set default pages and modal for the ones you need in builder settings.<\/p>\n<p><img fetchpriority=\"high\" decoding=\"async\" class=\"alignnone  wp-image-664\" src=\"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif\" alt=\"\" width=\"941\" height=\"669\" \/><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":72,"template":"","format":"standard","manualknowledgebasecat":[4],"manual_kb_tag":[],"class_list":["post-288","manual_kb","type-manual_kb","status-publish","format-standard","hentry","manualknowledgebasecat-how-to"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.6 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Trigger a Modal from a Custom Button in WordPress<\/title>\n<meta name=\"description\" content=\"Improve user interaction and engagement on your WordPress website by triggering a modal from a custom button. This comprehensive guide will show you how to implement a modal window that opens upon clicking a custom button, providing a seamless and interactive user experience. Follow these step-by-step instructions to enhance your website&#039;s functionality and captivate your audience with modal-triggering custom buttons.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Trigger a Modal from a Custom Button in WordPress\" \/>\n<meta property=\"og:description\" content=\"Improve user interaction and engagement on your WordPress website by triggering a modal from a custom button. This comprehensive guide will show you how to implement a modal window that opens upon clicking a custom button, providing a seamless and interactive user experience. Follow these step-by-step instructions to enhance your website&#039;s functionality and captivate your audience with modal-triggering custom buttons.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/\" \/>\n<meta property=\"og:site_name\" content=\"Digits Help\" \/>\n<meta property=\"article:modified_time\" content=\"2023-07-04T09:42:28+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/\",\"url\":\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/\",\"name\":\"How to Trigger a Modal from a Custom Button in WordPress\",\"isPartOf\":{\"@id\":\"https:\/\/help.unitedover.com\/digits\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif\",\"datePublished\":\"2018-11-24T13:59:18+00:00\",\"dateModified\":\"2023-07-04T09:42:28+00:00\",\"description\":\"Improve user interaction and engagement on your WordPress website by triggering a modal from a custom button. This comprehensive guide will show you how to implement a modal window that opens upon clicking a custom button, providing a seamless and interactive user experience. Follow these step-by-step instructions to enhance your website's functionality and captivate your audience with modal-triggering custom buttons.\",\"breadcrumb\":{\"@id\":\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#primaryimage\",\"url\":\"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif\",\"contentUrl\":\"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif\",\"width\":1305,\"height\":928},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/help.unitedover.com\/digits\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How To Trigger Modal From A Custom Button\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/help.unitedover.com\/digits\/#website\",\"url\":\"https:\/\/help.unitedover.com\/digits\/\",\"name\":\"Digits Help\",\"description\":\"WordPress Mobile Number Signup and Login\",\"publisher\":{\"@id\":\"https:\/\/help.unitedover.com\/digits\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/help.unitedover.com\/digits\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/help.unitedover.com\/digits\/#organization\",\"name\":\"UnitedOver\",\"url\":\"https:\/\/help.unitedover.com\/digits\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/help.unitedover.com\/digits\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/11\/logo512.png\",\"contentUrl\":\"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/11\/logo512.png\",\"width\":512,\"height\":512,\"caption\":\"UnitedOver\"},\"image\":{\"@id\":\"https:\/\/help.unitedover.com\/digits\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Trigger a Modal from a Custom Button in WordPress","description":"Improve user interaction and engagement on your WordPress website by triggering a modal from a custom button. This comprehensive guide will show you how to implement a modal window that opens upon clicking a custom button, providing a seamless and interactive user experience. Follow these step-by-step instructions to enhance your website's functionality and captivate your audience with modal-triggering custom buttons.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/","og_locale":"en_US","og_type":"article","og_title":"How to Trigger a Modal from a Custom Button in WordPress","og_description":"Improve user interaction and engagement on your WordPress website by triggering a modal from a custom button. This comprehensive guide will show you how to implement a modal window that opens upon clicking a custom button, providing a seamless and interactive user experience. Follow these step-by-step instructions to enhance your website's functionality and captivate your audience with modal-triggering custom buttons.","og_url":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/","og_site_name":"Digits Help","article_modified_time":"2023-07-04T09:42:28+00:00","og_image":[{"url":"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif","type":"","width":"","height":""}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/","url":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/","name":"How to Trigger a Modal from a Custom Button in WordPress","isPartOf":{"@id":"https:\/\/help.unitedover.com\/digits\/#website"},"primaryImageOfPage":{"@id":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#primaryimage"},"image":{"@id":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#primaryimage"},"thumbnailUrl":"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif","datePublished":"2018-11-24T13:59:18+00:00","dateModified":"2023-07-04T09:42:28+00:00","description":"Improve user interaction and engagement on your WordPress website by triggering a modal from a custom button. This comprehensive guide will show you how to implement a modal window that opens upon clicking a custom button, providing a seamless and interactive user experience. Follow these step-by-step instructions to enhance your website's functionality and captivate your audience with modal-triggering custom buttons.","breadcrumb":{"@id":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#primaryimage","url":"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif","contentUrl":"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/12\/1580052298.gif","width":1305,"height":928},{"@type":"BreadcrumbList","@id":"https:\/\/help.unitedover.com\/digits\/kb\/how-to-trigger-modal-from-a-custom-button\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/help.unitedover.com\/digits\/"},{"@type":"ListItem","position":2,"name":"How To Trigger Modal From A Custom Button"}]},{"@type":"WebSite","@id":"https:\/\/help.unitedover.com\/digits\/#website","url":"https:\/\/help.unitedover.com\/digits\/","name":"Digits Help","description":"WordPress Mobile Number Signup and Login","publisher":{"@id":"https:\/\/help.unitedover.com\/digits\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/help.unitedover.com\/digits\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/help.unitedover.com\/digits\/#organization","name":"UnitedOver","url":"https:\/\/help.unitedover.com\/digits\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/help.unitedover.com\/digits\/#\/schema\/logo\/image\/","url":"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/11\/logo512.png","contentUrl":"https:\/\/help.unitedover.com\/digits\/wp-content\/uploads\/sites\/2\/2018\/11\/logo512.png","width":512,"height":512,"caption":"UnitedOver"},"image":{"@id":"https:\/\/help.unitedover.com\/digits\/#\/schema\/logo\/image\/"}}]}},"acf":[],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/manual_kb\/288","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/manual_kb"}],"about":[{"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/types\/manual_kb"}],"author":[{"embeddable":true,"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/users\/1"}],"version-history":[{"count":1,"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/manual_kb\/288\/revisions"}],"predecessor-version":[{"id":2197,"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/manual_kb\/288\/revisions\/2197"}],"wp:attachment":[{"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/media?parent=288"}],"wp:term":[{"taxonomy":"manualknowledgebasecat","embeddable":true,"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/manualknowledgebasecat?post=288"},{"taxonomy":"manual_kb_tag","embeddable":true,"href":"https:\/\/help.unitedover.com\/digits\/wp-json\/wp\/v2\/manual_kb_tag?post=288"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}