[ Index ]
 

Code source de vtiger CRM 5.0.2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/modules/Users/ -> binaryfilelist.php (source)

   1  <?php
   2  
   3  /*********************************************************************************
   4  ** The contents of this file are subject to the vtiger CRM Public License Version 1.0
   5   * ("License"); You may not use this file except in compliance with the License
   6   * The Original Code is:  vtiger CRM Open Source
   7   * The Initial Developer of the Original Code is vtiger.
   8   * Portions created by vtiger are Copyright (C) vtiger.
   9   * All Rights Reserved.
  10  * 
  11   ********************************************************************************/
  12  
  13  require_once ('include/database/PearDatabase.php');
  14  
  15  //or die("Couldn't connect to database $dbDatabase");
  16  
  17  function getAttachmentsList()
  18  {
  19      global $theme,$adb;
  20      global $app_strings;
  21      global $mod_strings;
  22  
  23      $dbQuery = "SELECT templateid, filename,filesize,filetype,description,module ";
  24  
  25      $dbQuery .= "FROM vtiger_wordtemplates" ;
  26  
  27      $dbQuery .= " ORDER BY filename ASC";
  28  
  29      //echo $dbQuery;
  30  
  31      $result = $adb->query($dbQuery) or die("Couldn't get file list");
  32  
  33  $list = '<table border="0" cellpadding="5" cellspacing="1" class="FormBorder" width="90%">';
  34  
  35  $list .= '<tr height=20>';
  36  $list .='<td width="20%" class="moduleListTitle" style="padding:0px 3px 0px 3px;"><div align="center"><b>'.$app_strings['LBL_OPERATION'].'</b></div></td>';
  37  $list .= '';
  38  
  39  $list .= '<td width="20%" class="moduleListTitle" style="padding:0px 3px 0px 3px;"><b>';
  40  $list .= $app_strings['LBL_FILENAME'].'</b></td>';
  41  
  42  $list .= '<td width="10%" class="moduleListTitle" style="padding:0px 3px 0px 3px;"><b>';
  43  $list .= $mod_strings['LBL_MODULENAMES'].'</b></td>';
  44  
  45  $list .= '<td width="20%" class="moduleListTitle" style="padding:0px 3px 0px 3px;"><b>';
  46  $list .= $app_strings['LBL_UPD_DESC'].'</b></td>';
  47  
  48  $list .= '<td width="15%" class="moduleListTitle" style="padding:0px 3px 0px 3px;"><b>';
  49  $list .= $app_strings['LBL_TYPE'].'</td></b>';
  50  
  51  $list .= '<td width="15%" class="moduleListTitle" style="padding:0px 3px 0px 3px;"><b>';
  52  $list .= $app_strings['LBL_FILE'].'</b></td>';
  53  
  54  $list .= '</tr>';
  55  
  56  //$list .= '<tr><td COLSPAN="7" class="blackLine"><IMG SRC="themes/'.$theme.'/images//blank.gif"></td></tr>';
  57  
  58  $i=1;
  59  while($row = $adb->fetch_array($result))
  60  {
  61  
  62  
  63  if ($i%2==0)
  64  $trowclass = 'evenListRow';
  65  else
  66  $trowclass = 'oddListRow';
  67      $list .= '<tr class="'. $trowclass.'"><td style="padding:0px 3px 0px 3px;" align="center"><a href="index.php?module=Users&action=deletewordtemplate&record='.$row["templateid"].'"> Del </a> </td><td height="21" style="padding:0px 3px 0px 3px;">';
  68  
  69       $list .= $row["filename"]; 
  70  
  71      $list .= '</td>';
  72      
  73      $list .= '<td height="21" style="padding:0px 3px 0px 3px;">'.$row["module"].'</td>';
  74      $list .= '<td height="21" style="padding:0px 3px 0px 3px;">';
  75  
  76       $list .= $row["description"]; 
  77  
  78      $list .= '</td>';
  79      
  80      $list .= '<td height="21" style="padding:0px 3px 0px 3px;">';
  81  
  82      $list .= $row["filetype"]; 
  83  
  84      $list .= '</td>';
  85  
  86      $list .= '<td height="21" style="padding:0px 3px 0px 3px;">';
  87  
  88      $list .= '<a href="index.php?module=Users&action=downloadfile&record='.$row['templateid'] .'">';
  89  
  90      $list .= $app_strings['LBL_DOWNLOAD'];
  91  
  92      $list .= '</a></td></tr>';
  93  $i++;
  94  }
  95  
  96      $list .= '</table>';
  97  
  98  return $list;
  99  }
 100  ?>


Généré le : Sun Feb 25 10:22:19 2007 par Balluche grâce à PHPXref 0.7