Is there a way to render a controller to a different view then normal? I'm trying to pass some data from the controller to a non-default view. Meaning my controller is called:
class StocksRealtimeController extends AppController {
var $uses = 'StockRealtime';
function index(){
$action = '/TestView';
$this->set('stocksRT', $this->StockRealtime->find('all'));
//$this -> viewPath = 'Pages';
$this -> render('/TestView/index');
}
}
... and My view is in views->TestView->index.ctp
Another question I have is, how to pass that value to a PHP and not a ctp file outside of the CakePHP framework?
I have tried everything from here with no luck.