I have this like-sample
<div class="canvas_container">
<div id="messages_box" class="messages_box">
<div id="messages_label"></div>
</div>
<form id="data_form">
....
</form>
</div>
and once I saved correctly data I want to show the message to the user and invite him to login :
$data_complete = "<strong>" . _e("Data are updated. Goto at login page ","xxxxxxxx") . "<a href='" . wp_login_url() . "'></a></strong>";
?>
<script type="text/javascript">
$(document).ready(function(){
$("#messages_label").text(("<?= $data_complete; ?>").html());
$("#messages_box").show();
$("#data_form").reset();
});
</script>
<?php
but the message doesn't show inside messages_box... initial part goes under ::before of one of main div nodes, plus in Console I see this error:
Uncaught SyntaxError: missing ) after argument list
what I did wrong?....
Thanks to all in advance! Cheers!
Edit: solved!.... it was properly that _e() thing because it translate and echo/output the string passed to it. So I had to use __() to return just the translated string. Cheers!