| [ Index ] | PHP Cross Reference of Mambo 4.6.5 |
|
| [ Variables ] [ Functions ] [ Classes ] [ Constants ] [ Statistics ] | ||
[Summary view] [Print] [Text view]
1 <?php 2 /** 3 * @package Mambo 4 * @subpackage Menus 5 * @author Mambo Foundation Inc see README.php 6 * @copyright (C) 2000 - 2009 Mambo Foundation Inc. 7 * See COPYRIGHT.php for copyright notices and details. 8 * @license GNU/GPL Version 2, see LICENSE.php 9 * 10 * Redistributions of files must retain the above copyright notice. 11 * 12 * Mambo is free software; you can redistribute it and/or 13 * modify it under the terms of the GNU General Public License 14 * as published by the Free Software Foundation; version 2 of the License. 15 */ 16 17 /** ensure this file is being included by a parent file */ 18 defined( '_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' ); 19 20 /** 21 * Disaply content item link 22 */ 23 class content_item_link_menu_html { 24 25 function edit( &$menu, &$lists, &$params, $option, $content ) { 26 global $mosConfig_live_site; 27 ?> 28 <div id="overDiv" style="position:absolute; visibility:hidden; z-index:10000;"></div> 29 <script type="text/javascript"> 30 function submitbutton(pressbutton) { 31 var form = document.adminForm; 32 //form.name.value = form.componentid.options[form.componentid.selectedIndex].text; 33 //submitform( pressbutton ); 34 if (pressbutton == 'cancel') { 35 submitform( pressbutton ); 36 return; 37 } 38 if (pressbutton == 'redirect') { 39 submitform( pressbutton ); 40 return; 41 } 42 43 // do field validation 44 if (trim(form.name.value) == ""){ 45 alert( "<?php echo T_('Link must have a name'); ?>" ); 46 } else if (trim(form.content_item_link.value) == ""){ 47 alert( "<?php echo T_('You must select a Content to link to'); ?>" ); 48 } else { 49 form.link.value = "index.php?option=com_content&task=view&id=" + form.content_item_link.value; 50 form.componentid.value = form.content_item_link.value; 51 submitform( pressbutton ); 52 } 53 } 54 </script> 55 56 <form action="index2.php" method="post" name="adminForm"> 57 <table class="adminheading"> 58 <tr> 59 <th> 60 <?php echo $menu->id ? T_('Edit') : T_('Add');?> <?php echo T_('Menu Item :: Link - Content Item'); ?> 61 </th> 62 </tr> 63 </table> 64 65 <table width="100%"> 66 <tr valign="top"> 67 <td width="60%"> 68 <table class="adminform"> 69 <tr> 70 <th colspan="2"> 71 <?php echo T_('Details'); ?> 72 </th> 73 </tr> 74 <tr> 75 <td width="10%" align="right"> 76 <?php echo T_('Name:'); ?> 77 </td> 78 <td width="80%"> 79 <input class="inputbox" type="text" name="name" size="50" maxlength="100" value="<?php echo $menu->name; ?>" /> 80 </td> 81 </tr> 82 <tr> 83 <td width="10%" align="right" valign="top"> 84 <?php echo T_('Content to Link:'); ?> 85 </td> 86 <td width="80%"> 87 <?php echo $lists['content']; ?> 88 </td> 89 </tr> 90 <tr> 91 <td width="10%" align="right"><?php echo T_('Url:'); ?></td> 92 <td width="80%"> 93 <?php echo $lists['link']; ?> 94 </td> 95 </tr> 96 <tr> 97 <td width="10%" align="right" valign="top"> 98 <?php echo T_('On Click, Open in:'); ?> 99 </td> 100 <td width="80%"> 101 <?php echo $lists['target']; ?> 102 </td> 103 </tr> 104 <tr> 105 <td align="right"> 106 <?php echo T_('Parent Item:'); ?> 107 </td> 108 <td> 109 <?php echo $lists['parent']; ?> 110 </td> 111 </tr> 112 <tr> 113 <td valign="top" align="right"> 114 <?php echo T_('Ordering:'); ?> 115 </td> 116 <td> 117 <?php echo $lists['ordering']; ?> 118 </td> 119 </tr> 120 <tr> 121 <td valign="top" align="right"> 122 <?php echo T_('Access Level:'); ?> 123 </td> 124 <td> 125 <?php echo $lists['access']; ?> 126 </td> 127 </tr> 128 <tr> 129 <td valign="top" align="right"><?php echo T_('Published:'); ?></td> 130 <td> 131 <?php echo $lists['published']; ?> 132 </td> 133 </tr> 134 <tr> 135 <td colspan="2"> </td> 136 </tr> 137 </table> 138 </td> 139 <td width="40%"> 140 <table class="adminform"> 141 <tr> 142 <th> 143 <?php echo T_('Parameters'); ?> 144 </th> 145 </tr> 146 <tr> 147 <td> 148 <?php echo $params->render();?> 149 </td> 150 </tr> 151 </table> 152 </td> 153 </tr> 154 </table> 155 156 <input type="hidden" name="scid" value="<?php echo $menu->componentid; ?>" /> 157 <input type="hidden" name="option" value="<?php echo $option;?>" /> 158 <input type="hidden" name="id" value="<?php echo $menu->id; ?>" /> 159 <input type="hidden" name="componentid" value="" /> 160 <input type="hidden" name="link" value="" /> 161 <input type="hidden" name="menutype" value="<?php echo $menu->menutype; ?>" /> 162 <input type="hidden" name="type" value="<?php echo $menu->type; ?>" /> 163 <input type="hidden" name="task" value="" /> 164 <input type="hidden" name="hidemainmenu" value="0" /> 165 </form> 166 <script src="<?php echo $mosConfig_live_site;?>/includes/js/overlib_mini.js" type="text/javascript"></script> 167 <?php 168 } 169 } 170 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| Generated: Wed May 23 00:05:01 2012 | Cross-referenced by PHPXref 0.7 |
| Mambo API: Mambo is Free software released under the GNU/General Public License, Version 2 |