need help - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: need help (/showthread.php?tid=10707) |
need help - El Forum - 08-09-2008 [eluser]ebot[/eluser] i am building a weblog using CI i got probe with the edit; here is the on the view function edit($post_id) { $data['css'] = $this->css; $data['base'] = $this->base; $data['title']="My Blog CMS Navigation Page"; $data['heading']="Blog CMS"; $data['posts']= $this->Blog_model->get($post_id); $this->load->view('edit', $data); when i added some codes on the view side indorder to edit the post i get just empty fields here is the codes for the view: <?php echo $this->validation->error_string; ?> <?php foreach ($posts as $field): ?> <?php echo form_open('admin/update'); ?> <p>Title: <input type="text" name="<?php echo $field->title;?>" size="40"/></p> <p>Date-Time: <input type="text" name="<?php echo $field->postdate;?>" size="40"/> yyyy-mm-dd hh:mm</p> <p>Summary: <br/><textarea name="<?php echo $field->summary;?>" rows="5" cols="50"></textarea></p><br/> <p>Post:<br/><textarea name="<?php echo $field->post;?>" rows="15" cols="50"></textarea></p> <p><input type="submit" value="Update Post"></p> <?php endforeach; ?> </form> i will need help to work this out need help - El Forum - 08-09-2008 [eluser]vickel[/eluser] try to get <?php echo form_open('admin/update'); ?> out of the loop regards Vickel |