This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Register ajax action hook. | |
* | |
* When you have lots of ajax actions in your theme or plugin then | |
* this utility function is going to be quite handy! | |
* By default all actions are for logged in users. | |
* | |
* Usage: | |
* add_ajax( 'get_infinity_posts', 'prefix_get_infinity_posts' ); // for logged in only |