Source for file component_item_link.menu.html.php

Documentation is available at component_item_link.menu.html.php

  1. <?php
  2. /**
  3. @package Mambo
  4. @subpackage Menus
  5. @copyright  Refer to copyright.php
  6. @license http://www.gnu.org/copyleft/gpl.html GNU/GPL
  7. @author Mambo Foundation Inc see README.php
  8. */
  9.  
  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. /**
  14. * Display Component item link
  15. */
  16.  
  17.     function edit&$menu&$lists&$params$option {
  18.         global $mosConfig_live_site;
  19.         ?>
  20.         <div id="overDiv" style="position:absolute; visibility:hidden; z-index:10000;"></div>
  21.         <script language="javascript" type="text/javascript">
  22.         function submitbutton(pressbutton) {
  23.             var form = document.adminForm;
  24.             if ( pressbutton == 'cancel' ) {
  25.                 submitform( pressbutton );
  26.                 return;
  27.             }
  28.  
  29.             // do field validation
  30.             if ( trim(form.name.value) == "" ){
  31.                 alert( "<?php echo T_('Link must have a name')?>" );
  32.             } else if ( trim( form.link.value ) == "" ){
  33.                 alert( "<?php echo T_('You must select a Component to link to')?>" );
  34.             } else {
  35.                 submitform( pressbutton );
  36.             }
  37.         }
  38.         </script>
  39.  
  40.         <form action="index2.php" method="post" name="adminForm">
  41.         <table class="adminheading">
  42.         <tr>
  43.             <th>
  44.             <?php echo $menu->id T_('Edit'T_('Add');?> <?php echo T_('Menu Item :: Link - Component Item')?>
  45.             </th>
  46.         </tr>
  47.         </table>
  48.  
  49.         <table width="100%">
  50.         <tr valign="top">
  51.             <td width="60%">
  52.                 <table class="adminform">
  53.                 <tr>
  54.                     <th colspan="2">
  55.                     <?php echo T_('Details')?>
  56.                     </th>
  57.                 </tr>
  58.                 <tr>
  59.                     <td width="10%" align="right">
  60.                     <?php echo T_('Name:')?>
  61.                     </td>
  62.                     <td width="80%">
  63.                     <input class="inputbox" type="text" name="name" size="50" maxlength="100" value="<?php echo $menu->name?>" />
  64.                     </td>
  65.                 </tr>
  66.                 <tr>
  67.                     <td width="10%" align="right" valign="top">
  68.                     <?php echo T_('Component to Link:')?>
  69.                     </td>
  70.                     <td width="80%">
  71.                     <?php echo $lists['components']?>
  72.                     </td>
  73.                 </tr>
  74.                 <tr>
  75.                     <td width="10%" align="right"><?php echo T_('Url:')?></td>
  76.                     <td width="80%">
  77.                     <?php echo $lists['link']?>
  78.                     </td>
  79.                 </tr>
  80.                 <tr>
  81.                     <td width="10%" align="right" valign="top">
  82.                     <?php echo T_('On Click, Open in:')?>
  83.                     </td>
  84.                     <td width="80%">
  85.                     <?php echo $lists['target']?>
  86.                     </td>
  87.                 </tr>
  88.                 <tr>
  89.                     <td align="right">
  90.                     <?php echo T_('Parent Item:')?>
  91.                     </td>
  92.                     <td>
  93.                     <?php echo $lists['parent']?>
  94.                     </td>
  95.                 </tr>
  96.                 <tr>
  97.                     <td valign="top" align="right">
  98.                     <?php echo T_('Ordering:')?>
  99.                     </td>
  100.                     <td>
  101.                     <?php echo $lists['ordering']?>
  102.                     </td>
  103.                 </tr>
  104.                 <tr>
  105.                     <td valign="top" align="right">
  106.                     <?php echo T_('Access Level:')?>
  107.                     </td>
  108.                     <td>
  109.                     <?php echo $lists['access']?>
  110.                     </td>
  111.                 </tr>
  112.                 <tr>
  113.                     <td valign="top" align="right"><?php echo T_('Published:')?></td>
  114.                     <td>
  115.                     <?php echo $lists['published']?>
  116.                     </td>
  117.                 </tr>
  118.                 <tr>
  119.                     <td colspan="2">&nbsp;</td>
  120.                 </tr>
  121.                 </table>
  122.             </td>
  123.             <td width="40%">
  124.                 <table class="adminform">
  125.                 <tr>
  126.                     <th>
  127.                     <?php echo T_('Parameters')?>
  128.                     </th>
  129.                 </tr>
  130.                 <tr>
  131.                     <td>
  132.                     <?php echo $params->render();?>
  133.                     </td>
  134.                 </tr>
  135.                 </table>
  136.             </td>
  137.         </tr>
  138.         </table>
  139.  
  140.         <input type="hidden" name="option" value="<?php echo $option;?>" />
  141.         <input type="hidden" name="id" value="<?php echo $menu->id?>" />
  142.         <input type="hidden" name="menutype" value="<?php echo $menu->menutype?>" />
  143.         <input type="hidden" name="type" value="<?php echo $menu->type?>" />
  144.         <input type="hidden" name="task" value="" />
  145.         <input type="hidden" name="hidemainmenu" value="0" />
  146.         </form>
  147.         <script language="Javascript" src="<?php echo $mosConfig_live_site;?>/includes/js/overlib_mini.js"></script>
  148.         <?php
  149.     }
  150. }
  151. ?>

Documentation generated on Mon, 05 May 2008 16:18:05 +0400 by phpDocumentor 1.4.0