Annotation of /mambo/branches/4.6/administrator/components/com_modules/toolbar.modules.php
Parent Directory
|
Revision Log
Revision 964 - (view) (download)
| 1 : | root | 1 | <?php |
| 2 : | /** | ||
| 3 : | elpie | 964 | * @package Mambo |
| 4 : | root | 1 | * @subpackage Modules |
| 5 : | cauld | 948 | * @copyright Refer to copyright.php |
| 6 : | root | 1 | * @license http://www.gnu.org/copyleft/gpl.html GNU/GPL |
| 7 : | elpie | 964 | * @author Mambo Foundation Inc see README.php |
| 8 : | csouza | 297 | */ |
| 9 : | root | 1 | |
| 10 : | /** ensure this file is being included by a parent file */ | ||
| 11 : | defined( '_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' ); | ||
| 12 : | |||
| 13 : | require_once( $mainframe->getPath( 'toolbar_html' ) ); | ||
| 14 : | switch ($task) { | ||
| 15 : | |||
| 16 : | case 'editA': | ||
| 17 : | case 'edit': | ||
| 18 : | $cid = mosGetParam( $_POST, 'cid', 0 ); | ||
| 19 : | if ( !is_array( $cid ) ){ | ||
| 20 : | $mid = mosGetParam( $_POST, 'id', 0 );; | ||
| 21 : | } else { | ||
| 22 : | $mid = $cid[0]; | ||
| 23 : | } | ||
| 24 : | |||
| 25 : | $published = 0; | ||
| 26 : | if ( $mid ) { | ||
| 27 : | $query = "SELECT published FROM #__modules WHERE id='$mid'"; | ||
| 28 : | $database->setQuery( $query ); | ||
| 29 : | $published = $database->loadResult(); | ||
| 30 : | } | ||
| 31 : | $cur_template = $mainframe->getTemplate(); | ||
| 32 : | TOOLBAR_modules::_EDIT( $cur_template, $published ); | ||
| 33 : | break; | ||
| 34 : | |||
| 35 : | case 'new': | ||
| 36 : | TOOLBAR_modules::_NEW(); | ||
| 37 : | break; | ||
| 38 : | |||
| 39 : | default: | ||
| 40 : | TOOLBAR_modules::_DEFAULT(); | ||
| 41 : | break; | ||
| 42 : | } | ||
| 43 : | ?> |
| ViewVC Help | |
| Powered by ViewVC 1.0.0 |
Web Hosting provided by Network Redux.

