Someone who can help me?
Someone who can help me?
In general, the view that mounts the main body of the page for the user to see is also the same one that at the end has a hidden modal window, which appears when the user clicks somewhere. However, even if this window comes from another view file, for the web browser they are posted by the same control, sequentially, then they would be on the same page. So, via javascript or JQuery, you can restore forms values in the main body for modal or modal for forms in the main body.
Example: displaying an alert with the value, via a button in the main body, of a checkbox that could be in the modal (call modal, click and see what appears again):
<a href="#" onclick="if($("#minha_checkbox").is(':checked')){alert('Marcado!');}else{alert("Vazio');}>Clique</a>
But if there are values posts, ie reloads the page, it is impossible to store values in the view. You need to receive the data per post in the control, example $this->input->post('minha_checkbox');
, and play the data you receive in session (from CodeIgniter), bank, flashdata or cookie obligatorily. And then, when you need them, check what they were, and send them to the view, either the modal or main body, to continue working with them.