Reputation: 954
I have this pblm, i have been trying to create master view layout using jquery & codeigniter. What i was trying to do is simple, i have following files
template.php & content.php
template.php have a
<div id="container">
and i want to load one of my div's from content.php based on the link clicked. everything gets loaded into #container div except the form_open tag returns error. i have configured it in autoload & also tried to load it in controller, but both are not working
<div id="container">
<h2>Create New User</h2>
<?=form_open('form/createuser'); ?>
.
.
<?=form_close(); ?>
</div>
Upvotes: 0
Views: 4417
Reputation:
@RahulArackal, You can please add below code in the beginning of your controller code.
$this->load->helper('form');
Also u can do other thing like auto load this helper file in autoload.php.
$autoload['helper'] = array('form');
Also you should apply echo before the form_open().
Let me know if still any issues.
Upvotes: 1
Reputation: 966
Try this
<?php echo form_open('form/createuser'); ?>
.
.
<?php echo form_close(); ?>
Upvotes: 0