Skip to content

Instantly share code, notes, and snippets.

@nsssim
Last active August 29, 2015 14:14
Show Gist options
  • Save nsssim/5eb75aae3b6c378745cf to your computer and use it in GitHub Desktop.
Save nsssim/5eb75aae3b6c378745cf to your computer and use it in GitHub Desktop.
<?php
//controller
//-------------------------------------
function index()
{
$this->load->model('list_four_mdl'); // load the file welcome_mdl.php
$data1['records'] = $this->list_four_mdl->get_fourn(); //
$data2['records2'] = $this->list_four_mdl->get_enga(); //
$data3['xxx']=$data1;
$data3['yyy']=$data2;
// $this->facture_img_mdl->get_facture();
$this->load->view('facture_upload_vew',$data3);
}
//view
//------------------------------------
$r1=$xxx['records'];
$r2=$yyy['records2'];
foreach ($r1 as $row)
{
echo '<option value='.$row->id_r1.'>'. $row->id_r1 . '</option>';
}
foreach ($r2 as $row)
{
echo '<option value='.$row->id_r2.'>'. $row->id_r2. '</option>';
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment