This is my wordpress listing site. Here i want to get alert popup when i click Save & Preview button. so please give me a proper solution for this.
wp:
CodePudding user response:
If you are using Elementor then it is very easy. use Elementor popup and create popup which you want then add popup link to your "save and preview" button.
CodePudding user response:
Put this one at end of the code before tag or put in footer file of your child theme
<script language="javascript" type="text/javascript">
jQuery(document).ready(function() {
jQuery('#btnsave').click(function() { // #btnsave is element ID, you can replace with element ID or Class
alert('Hello');
});
});
</script>