1
Opa,
I have the following function for an ajax login
function show_login_client_enter(id) {
var url = 'store/content/validate_user_client_action.php';
var method = 'POST';
var params = 'id_store='+id;
params += '&user_acao=1';
params += '&user_email='+document.getElementById('user_email').value;
params += '&user_pwd='+document.getElementById('user_pwd').value;
var container_id = 'loading_validate_client_action_login';
var loading_text = 'Loading...' ;
ajax (url, method, params, container_id, loading_text) ;
$(document).ajaxComplete(scripts);
}
In the PHP file validate_user_client_action.php, when the user logs in I need to refresh a div with data from another php file, but how to call a function or how to refresh a php return from an ajax request?
I need the return of the login in php of something like:
echo '
<script type="text/javascript">
$("#loading_client_content_info").load("store/content/client_info.php");
</script>
';
This . load code does not return anything, nor in the console.
I couldn’t make that validate_user_client_action.php return what should return from client_info.php ? Because the way you’re trying is redundant, and it doesn’t make sense.
– Daniel Omine