19 lines
577 B
PHP
19 lines
577 B
PHP
<?php
|
|
class Application_Controller_Plugin_Xml extends Zend_Controller_Plugin_Abstract
|
|
{
|
|
public function dispatchLoopShutdown()
|
|
{
|
|
require_once 'Scores/PagePrint.php';
|
|
$controller = $this->_request->getControllerName();
|
|
$action = $this->_request->getActionName();
|
|
|
|
$layout = Zend_Layout::getMVCInstance();
|
|
if ($layout->isEnabled()) {
|
|
$view = $layout->getView();
|
|
$page = new PagePrint($controller, $action);
|
|
if ($page->exportable('xml') && !empty($view->exportObjet)) {
|
|
$page->objectToXML($view->exportObjet, $this->_request->getParams());
|
|
}
|
|
}
|
|
}
|
|
} |