@joe Bloggs – I will have to do some digging into WP core for the login / registration pages. You are correct they do not use wp_head/wp_footer so not only do our JS & CSS not load but the popups are not renderable there either currently.
I will look to see if there is a way to do so, I am assuming there is, but it likely involves you hooking our JS / CSS registration to new events on your end.
That would be a really great help, I really appreciate that.
Many thanks for your time.
Hi Daniel,
I’ve been searching around for a solution. I guess I should be able to use the login_footer or login_enqueue_scripts to load the javascript to the wp-login page, correct?
Your documentation has been very helpful too and I found few lines that could possibly work, so would something like this work to get the popup pop on the login page?
<?php
add_action( 'login_footer', 'my_custom_popup_scripts', 500 );
function my_custom_popup_scripts() { ?>
<script type="text/javascript">
(function ($, document, undefined) {
// this should be the line that triggers the popup
<a href="#" onclick="jQuery('#popmake-123').popmake('open')">Sign Up For Our Newsletter!</a>
}(jQuery, document))
</script><?php
}
Or would I need to specify the URL to the actual script, something like this in the functions.php?
add_action( ‘login_enqueue_scripts’, ‘enqueue_my_script’ );
function enqueue_my_script( $page ) {
wp_enqueue_script( 'my-script', 'http://domain.com/path/myjs-file.js', null, null, true );
}
I’m an amateur when it comes to jquery and javascript or even php, so sorry if i’m totally wrong here, just trying to find a solution that would work..
@joe Bloggs – In this case you need to not only load our scripts & css, but also the popups themselves need to be loaded. You would need to call the correct functions on the footer of the login page that we call on wp_footer.
Maybe do a search on our github for wp_head, wp_footer & wp_enqueue_scripts. Whatever you see attached to those points likely needs to be attached to login page hooks as well.
Hope that helps.
Closing this ticket due to inactivity. If your still having an issue post here and we will continue troubleshooting.
Please take a moment to rate and review the plugin and or support.