Hi ,
I am unable to call the javascript script in template file while using ajax functionality. please find the code below
DemoPage.php
function DemoContent()
{
/*$records = DataObject::get( "ProductMainPage", "", "", "", "");*/
$records = DataObject::get( "DemoPage", "ParentID = $this->ID", "", "", "");
return $this->customise(array(
'DemoMainPage' => $records
))->renderWith('DemoContent');
}
DemoContent.ss
<script>
function samplefunction()
{
........
}
</script>
<div>
[demo value]
</div>
http://localhost/myproject/demo-page/DemoContent - unable call the javascript inside the render template file. please do needful . let me know if you need any clarification.
Regards,
thisIsRam