I don't know what i'm doing wrong and im stuck in this part of my project so any help would be appreciated
here is my html:
<form id="form_search" method="post" action="/controler/something">
<select id="tip_fam" maxlength="100" >
<option value="1">something 001</option>
<option value="2">something 002</option>
<option value="3">something 003</option>
<ul id="print" class="bot"><li>Print</li></ul>
</form>
JS:
$("#print").click(function(){
url = base_url+"index.php/almacen/product/create_pdf/"+$("#tip_fam").val();
window.open(url,'',"width=800,height=600,menubars=no,resizable=no;")
});
Php (codeigniter) :
public function create_pdf(){
$tip_fam = $this->input->post('tip_fam');
i thought i could get the value of the select this way but when i print it in a var_dump(), it shows me "boolean false".
window.open... need to submit form to_blanktarget, or use agetpostdata you have to submit the form. What you're doing is just opening a new window.getparams or codeigniter url segments