0
I have a login validation in js that generates an alert:
<script type="text/javascript">
var mensagem = "<?php echo (isset( $_SESSION['erroLogin'])? $_SESSION['erroLogin'] : "false");?>";
<?php unset($_SESSION['erroLogin']);?>
if (mensagem != "false") {
alert(mensagem);
}
</script>
But I would like to use a custom alert that I have as an example on a button
<button class="md-btn" data-message="mensagem de alerta" data-pos="bottom-right">alerta</button>
Thanks in advance.
You want Alert to be called when you click the button?
– Sergio