Source for file languages.tpl.php

Documentation is available at languages.tpl.php

  1. <?php 
  2. /**
  3. @package Mambo
  4. @subpackage Languages
  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. defined'_VALID_MOS' or die'Direct Access to this location is not allowed.' )?>
  10. <?php global $mosConfig_locale;?>
  11. <script type="text/javascript">
  12. function submitbutton(pressbutton) {
  13.     var form = document.adminForm;
  14.     if(pressbutton == 'remove') {
  15.         if(getSelectedRadio('adminForm','lang') == "en") {
  16.             alert( "<?php echo T_('You cannot delete English.'?>" );
  17.         } else {
  18.             var defaultlang=document.adminForm.defaultlang.value;
  19.             var mylang = document.adminForm.lang;
  20.             var candelete=true;
  21.             for(i=0;i<mylang.length;i++) {
  22.                 if(mylang[i].checked && mylang[i].value==defaultlang) {
  23.                     candelete=false;
  24.                     alert( "<?php echo T_('You cannot delete default language.'?>" );
  25.                     break;
  26.                 }
  27.             }
  28.             if(candelete)
  29.                 submitform( pressbutton );
  30.  
  31.         }
  32.     } else if (pressbutton == 'translate')   {
  33.         if (getSelectedRadio('adminForm','lang') == "en") {
  34.             alert( "<?php echo T_('You cannot translate default English.'?>" );
  35.         } else {
  36.             submitform( pressbutton );
  37.         }
  38.     }else{
  39.         submitform( pressbutton );
  40.     }
  41. }
  42. </script>
  43.  
  44.  
  45. <table class="adminlist" id="lang_table" cellpadding="3" cellspacing="0" width="80%">
  46. <thead>
  47. <tr>
  48.     <th style="width:10px">&nbsp;</th>
  49.     <th><?php echo T_('Language'?></th>
  50.     <th><?php echo T_('Country - Region'?></th>
  51.     <th><?php echo T_('Default'?></th>
  52.     <th><?php echo T_('Character Set'?></th>
  53.     <th><?php echo T_('Version'?></th>
  54.     <th><?php echo T_('Date'?></th>
  55. </tr>
  56. </thead>
  57. <tbody>
  58. <?php for ($i=0$n=count$rows )$i $n$i++:  $row $rows[$i];?>
  59.     <tr id="<?php echo $i;?>">
  60.         <td style="width:10px">
  61.         <input type="radio" id="cb<?php echo $i;?>" name="lang" value="<?php echo $row->name?>" onClick="isChecked(this.checked);" />
  62.         </td>
  63.         <td>
  64.         <a href="#" onclick="hideMainMenu();return listItemTask('cb<?php echo $i;?>','edit')"><?php echo $row->title?></a>
  65.         </td>
  66.         <td>
  67.         <?php echo $row->territory ?>
  68.         </td>
  69.         <td>
  70.         <?php $default (mamboCore::get('mosConfig_locale'== $row->name0?>
  71.         <a href="javascript: void(0);" onClick="return listItemTask('cb<?php echo $i;?>','default')">
  72.         <img src="images/<?php echo $default 'tick.png' 'publish_x.png';?>" width="12" height="12" border="0" alt="<?php echo $default T_('Yes'T_('No');?>" />
  73.         </a>
  74.         </td>
  75.         <td>
  76.         <?php echo $row->charset ?>
  77.         </td>
  78.         <td>
  79.         <?php echo $row->version?>
  80.         </td>
  81.         <td>
  82.         <?php echo $row->creationdate?>
  83.         </td>
  84.     </tr>
  85. <?php endfor?>
  86. </tbody>
  87. </table>
  88. <input type="hidden" name="defaultlang" value="<?php echo $mosConfig_locale;?>" />
  89. <script type="text/javascript">
  90. table = new Table('lang_table');  
  91. table.makeSortable(1,"null,str,null,str,str,date");
  92. </script>

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