mirror of
https://github.com/bcit-ci/CodeIgniter.git
synced 2025-02-20 11:13:29 +08:00
...
parent
907f966bc7
commit
01fd09ea05
@ -194,4 +194,19 @@ foreach ($sub_contents as $part)
|
||||
$content->load($part->id, $part->partial, $part->data);
|
||||
}
|
||||
|
||||
[/code]
|
||||
|
||||
[size=5]Independent:[/size]
|
||||
|
||||
View Objects can also be created independently, they can have their own partials and then they can be added to the master view.
|
||||
[code]
|
||||
|
||||
$content = new View();
|
||||
|
||||
$content->load('part1','partial_file',$article_1);
|
||||
$content->load('part2','partial_file',$article_2);
|
||||
$content->load('part3','partial_file',$article_3);
|
||||
|
||||
$this->view->load('content', $content);
|
||||
|
||||
[/code]
|
Loading…
x
Reference in New Issue
Block a user