- wp native ajax fix

This commit is contained in:
nikitozzzzzzz
2018-08-15 13:24:22 +03:00
parent a6aef845b8
commit 6e0836a4f8
20 changed files with 56 additions and 82 deletions
+10 -4
View File
@@ -72,10 +72,16 @@ if ( ! class_exists( 'um\admin\core\Admin_Menu' ) ) {
<script type="text/javascript">
jQuery( 'a.um-admin-rating-link' ).click(function() {
jQuery.post(
'<?php echo UM()->get_ajax_route( get_class( $this ), 'ultimatemember_rated' ) ?>',
{}
);
jQuery.ajax({
url: wp.ajax.settings.url,
type: 'post',
data: {
action: 'um_rated'
},
success: function(){
}
});
jQuery(this).parent().text( jQuery( this ).data( 'rated' ) );
});
</script>