Ok.. I have created a new layout - default.thtml
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<?php echo $html->charset('UTF-8');?>
<title>My Site title</title>
<?php echo
$html->css('mysite','stylesheet',array('media'=>'screen'));?>
<?php echo $javascript->link('prototype.js'); ?>
<?php echo
$javascript->link('scriptaculous.js?load=builder,effects,dragdrop,controls,slider');?>
<?php echo $javascript->link('scrolltable.js'); ?>
</head>
<body>
<?php echo renderElement('header'); ?>
<div id="main"> <!--main div for the page starts-->
<?php
echo $content_for_layout;
?>
</div><!--main div for the whole page ends-->
<?php echo renderElement('footer'); ?>
<?php echo $javascript->link('nemomenu.js'); ?>
</body>
</html>
Note I have the render the element header in the layout.
And my ajax.thtml looks like <?php echo $content_for_layout; ?>
On click of any link (menu), I am loading the new page with
render('newpage', 'ajax')
Now the problem is the header is repeating when I click on the links.
How can I solve this ?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~----------~----~----~----~------~----~------~--~---