1
It is possible to get a result of a Javascript function and play this result inside a Modal?
I have this function:
<script>
$('#download').click(function() {
document.getElementById('xxxx').disabled=false
document.getElementById('xxxx').disabled=false
var formData = $(document.forms[0]).serialize().split('&').join('\n');
this.href = 'data: ,' + formData ;
document.getElementById('xxxx').disabled=true
document.getElementById('xxxxx').disabled=true
});
</script>
The result "formData" would have to be played inside a modal Popup. Its code:
<div class="bs-example">
<!-- Button HTML (to Trigger Modal) -->
<a href="#myModal" class="btn btn-lg btn-primary" data-toggle="modal" >Clique aqui para ver a janela</a>
<!-- Modal HTML -->
<div id="myModal" class="modal fade">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h4 class="modal-title">Atenção!</h4>
</div>
<div class="modal-body">
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
<button type="button" class="btn btn-primary">Salvar tudo</button>
</div>
</div>
</div>
</div>
</div>
Dear; I ask you to disregard the above question, it was "stung".
– user54154
What do you mean by perforated? No one changed anything in the question, only there was a code formatting and title improvement. If it is perforated also you can edit it and add more information.
– user28595
I thought she n had gone formatted and it would get messy. It was my first interaction to this forum. Grateful.
– user54154
this is not a forum, it is a Q&A, just to make the difference clear. You can edit the question as many times as you want and if you don’t have answers, you can delete it too.
– user28595
Grateful for the response.
– user54154