6 years, 6 months ago
Does anyone know how to display a message with Ajax/jQuery after a normal redirect?
Specifically I need it for code I’m trying to put together to close most of the site for not-logged-in users, so for example when they try to open the members section they get redirected back to the home page, where they will see a message: “please log in or register first”
I’ve tried several searches on this, but was only able to pull up Ajax as alternative for redirect examples; I need a variable message after regular redirects.
Apologies if it’s not OK to post a general Ajax question like this in the miscellaneous section.
I think this page provides some clues. I’ll get back to that after some late lunch… [passing out…]
I think Ajax messages are already used in Buddypress. This is in the template somewhere:
<?php do_action( 'template_notices' ) // (error/success feedback) ?>
Could a “please log in or register first” message use the same function?
Follow BuddyPress on Twitter •
Contact Us •
Terms of Service