Welcome Guest, Not a member yet? Register   Sign In
My form is not submitting
#7

(02-04-2015, 02:44 AM)andyblem Wrote: I changed my second view a bit and its now submitting but I now have a new problem my deleteOffice function in my phones controller is not executing all of its instructions

Here is my new code

Code:
<div align="center">
<?php
$this->load->helper('form');
foreach($offices as $office)
{
     echo $office['names'];
     echo form_open('phones/deleteOffice');
      $data = array( 'name'        => 'office',
                    'value'       => $office['id']);
              
     echo form_submit('submit', 'Delete Ofiice');
     echo form_close();
}
?>
</div>

1. Your form does not contain a field named 'office', so $this->input->post('office') in your controller is probably not going to give you an office to delete. One method of adding this data to the form would be to use echo form_hidden('office', $office['id']);.
2. The align attribute in your HTML was deprecated in 1999.
Reply


Messages In This Thread
My form is not submitting - by andyblem - 02-03-2015, 07:08 AM
RE: My form is not submitting - by mwhitney - 02-03-2015, 12:38 PM
RE: My form is not submitting - by andyblem - 02-04-2015, 12:17 AM
RE: My form is not submitting - by andyblem - 02-04-2015, 02:44 AM
RE: My form is not submitting - by mwhitney - 02-04-2015, 07:54 AM
RE: My form is not submitting - by andyblem - 02-12-2015, 12:59 AM
RE: My form is not submitting - by InsiteFX - 02-04-2015, 02:51 AM
RE: My form is not submitting - by andyblem - 02-04-2015, 06:58 AM
RE: My form is not submitting - by InsiteFX - 02-12-2015, 05:09 AM



Theme © iAndrew 2016 - Forum software by © MyBB