ilikeme
(Eliyaoo12)
1
Who can i do the HTML header like <body> will show by himself.
sitecontroller.php
<?php
class SiteController extends CController {
public function actionIndex() {
print "hello";
}
}
?>
website.com/index.php:
<html>
<head>
<title>website title</title>
</head>
<body>
hello
</body>
</html>
I hope you understand what I mean.
mdomba
(Maurizio Domba Cerin)
2
Your question is not clear to me can you explain it more?
thyseus
(Thyseus)
3
i think you need to render a layout file
$this->layout = 'examplelayout';
$this->renderText('Helloworld');
and create a file views/layouts/examplelayout.php:
<html>
<head></head>
<body><?php echo $content; ?></body>
</html>