Source for file component_item_link.class.php
Documentation is available at component_item_link.class.php
* @copyright Refer to copyright.php
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL
* @author Mambo Foundation Inc see README.php
/** ensure this file is being included by a parent file */
defined( '_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' );
* Component item link class
function edit( &$uid, $menutype, $option ) {
global $database, $my, $mainframe;
// fail if checked out not by 'me'
if ($menu->checked_out &&
$menu->checked_out <>
$my->id) {
echo
"<script>alert('".
sprintf(T_('The module %s is currently being edited by another administrator'),$menu->title ).
"'); document.location.href='index2.php?option=$option'</script>\n";
$menu->checkout( $my->id );
// load values for new entry
$menu->type =
'component_item_link';
$menu->menutype =
$menutype;
$temp =
explode( '&Itemid=', $menu->link );
.
"\n WHERE a.link = '".
$temp[0] .
"'"
$database->setQuery( $query );
$components =
$database->loadResult();
$lists['components'] =
$components;
$lists['components'] .=
'<input type="hidden" name="link" value="'.
$menu->link .
'" />';
$query =
"SELECT CONCAT( a.link, '&Itemid=', a.id ) AS value, a.name AS text"
.
"\n WHERE a.published = '1'"
.
"\n AND a.type = 'components'"
.
"\n ORDER BY a.menutype, a.name"
$database->setQuery( $query );
$components =
$database->loadObjectList( );
// Create a list of links
$lists['components'] =
mosHTML::selectList( $components, 'link', 'class="inputbox" size="10"', 'value', 'text', '' );
// build html select list for target window
// build the html select list for ordering
// build the html select list for the group access
// build the html select list for paraent item
// build published button option
// build the url link output
// get params definitions
$params =
& new mosAdminParameters( $menu->params, $mainframe->getPath( 'menu_xml', $menu->type ), 'menu' );
Documentation generated on Mon, 05 May 2008 16:18:05 +0400 by phpDocumentor 1.4.0