[ Index ]
 

Code source de vtiger CRM 5.0.2

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

title

Body

[fermer]

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

   1  <?php
   2  /*********************************************************************************
   3  ** The contents of this file are subject to the vtiger CRM Public License Version 1.0
   4   * ("License"); You may not use this file except in compliance with the License
   5   * The Original Code is:  vtiger CRM Open Source
   6   * The Initial Developer of the Original Code is vtiger.
   7   * Portions created by vtiger are Copyright (C) vtiger.
   8   * All Rights Reserved.
   9  *
  10   ********************************************************************************/
  11  require_once ('include/database/PearDatabase.php');
  12  require_once ('include/utils/utils.php');
  13  
  14  $inv_type='Inventory';
  15  $inv_tandc=addslashes($_REQUEST['inventory_tandc']);
  16  
  17  $sql="select * from vtiger_inventory_tandc where type='".$inv_type."'";
  18  $result = $adb->query($sql);
  19  $inv_id = $adb->query_result($result,0,'id');
  20  if($inv_id == '')
  21  {
  22          $inv_id=$adb->getUniqueID('vtiger_inventory_tandc');
  23          $sql="insert into vtiger_inventory_tandc values( '".$inv_id ."','".$inv_type."','". $inv_tandc."')";
  24  }
  25  else
  26  {
  27      $sql="update vtiger_inventory_tandc set type = '".$inv_type."', tandc = '".$inv_tandc."' where id = ".$inv_id;
  28  }
  29  $adb->query($sql);
  30  
  31  header("Location: index.php?module=Users&action=OrganizationTermsandConditions&parenttab=Settings");
  32  ?>


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