[eluser]hamzakhan[/eluser]
my form
Code:
<?php echo form_open_multipart('admin/catagory/Add');?>
<table width="92%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<th align="left">Catagory Name</th>
</tr>
<tr>
<td><input name="txt_cat_name" type="text"></td>
</tr>
<tr>
<th align="left">Catagory Description</th>
</tr>
<tr>
<td><textarea name="txt_cat_des" cols="50" rows="12"></textarea></td>
</tr>
<tr>
<th align="left">Catagory Image</th>
</tr>
<tr>
<td><input name="txt_cat_image_upload" type="file"></td>
</tr>
<tr>
<td><input name="" type="submit" value="Add"></td>
</tr>
<tr>
<td> </td>
</tr>
</table>
</form>
function
Code:
//add catagory
function Add()
{
$config['upload_path'] = 'assets/images/catagory/';
$config['allowed_types'] = 'gif|jpg|png';
$config['max_size'] = '100';
$config['max_width'] = '1024';
$config['max_height'] = '768';
$this->load->library('upload', $config);
$this->upload->do_upload();
}
image is not selected error blah blah
plz tell me what else is left in uploading