Source for file pnadmin.php
Documentation is available at pnadmin.php
* Zikula Application Framework
* @copyright (c) 2002, Zikula Development Team
* @link http://www.zikula.org
* @version $Id: pnadmin.php 24342 2008-06-06 12:03:14Z markwest $
* @license GNU/GPL - http://www.gnu.org/copyleft/gpl.html
* @package Zikula_Value_Addons
* the main administration function
* This function is the default function, and is called whenever the
* module is initiated without defining arguments. As such it can
* be used for a number of things, but most commonly it either just
* shows the module menu and returns or calls whatever the module
* designer feels should be the default function (often this is the
* @link http://www.markwest.me.uk
* @return string HTML string
// Return the output that has been generated by this function
return $pnRender->fetch('avantgo_admin_main.htm');
* View items that would be displayed by the module within PN framework
* @link http://www.markwest.me.uk
* @param 'startnum' the starting article numbner
* @return strong HTML string
// Get all the items from the API
array('startnum' => $startnum,
'numitems' => pnModGetVar('AvantGo', 'itemsperpage')));
$pnRender->assign('storyitems', $items);
// Return the output that has been generated by this function
return $pnRender->fetch('avantgo_admin_view.htm');
* This is a standard function to modify the configuration parameters of the
* @link http://www.markwest.me.uk
* @return string HTML string
// assign all module vars
// Return the output that has been generated by this function
return $pnRender->fetch('avantgo_admin_modifyconfig.htm');
* This is a standard function to update the configuration parameters of the
* module given the information passed back by the modification form
* @link http://www.markwest.me.uk
* @param 'itemsperpage' the number of items to display on the module page
* @return bool true if update successful, false otherwise
// Confirm authorisation code.
// Update module variables.
// Let any other modules know that the modules configuration has been updated
pnModCallHooks('module','updateconfig','AvantGo', array('module' => 'AvantGo'));
// the module configuration has been updated successfuly
// This function generated no output, and so now it is complete we redirect
// the user to an appropriate page for them to carry on their work
|