[eluser]Arun Joshi[/eluser]
I have created a test page ajaxtest.php in controllers. Its structure is
Code:
<?php
class Ajaxtest extends Controller {
function index()
{
echo '<br />ajax test fn';
$this->load->library('ajax');
echo $this->ajax->link_to_remote("show", array('url' => '/view/view_ajax', 'update' => 'divblock'));
}
}
?>
I also have another controller , which having the following structure.
Code:
<?php
class ajaxcontent extends Controller {
function index()
{
echo 'Its some ajax content to display in ajaxtest page...<br />';
}
}
?>
How can I load the ajaxcontent controller data in a div (divblock) in ajaxtext controller? Where should I declare the div to show the content? where to include the javascript filess.
Now I have tried more than two hours with this.
Thanks