<?php
// we enter to IndexController->indexAction
class IndexController extends ControllerBase
{
public function indexAction()
{
// take content from first controller
$content1 = getContentFromController('IndexController', 'firstAction');
//take content from second controller
$content2 = getContentFromController('MyController', 'indexAction');
echo $content1 . $content2; // i want to take this string "<h1>hello world</h1>"
}
public function firstAction()
{
echo '<h1>hello ';
}
}
//another controller
class MyController extends ControllerBase
{
public function indexAction()
{
echo 'world</h1>';
}
}
Anybody know how i can do it???