[ Index ] |
|
Code source de vtiger CRM 5.0.2 |
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 14 require_once ('include/database/PearDatabase.php'); 15 require_once ('include/utils/utils.php'); 16 17 $profilename=$_REQUEST['profile_name']; 18 19 if(isset($_REQUEST['dup_check']) && $_REQUEST['dup_check']!='') 20 { 21 $query = 'select profilename from vtiger_profile where profilename="'.$profilename.'"'; 22 $result = $adb->query($query); 23 24 if($adb->num_rows($result) > 0) 25 { 26 echo 'A Profile in the specified name "'.$profilename.'" already exists'; 27 die; 28 }else 29 { 30 echo 'SUCESS'; 31 die; 32 } 33 34 } 35 36 37 global $theme; 38 $theme_path="themes/".$theme."/"; 39 $image_path=$theme_path."images/"; 40 $smarty = new vtigerCRM_Smarty; 41 42 if(isset($_REQUEST['parent_profile']) && $_REQUEST['parent_profile'] != '') 43 $smarty->assign("PARENT_PROFILE",$_REQUEST['parent_profile']); 44 if(isset($_REQUEST['radio_button']) && $_REQUEST['radio_button'] != '') 45 $smarty->assign("RADIO_BUTTON",$_REQUEST['radio_button']); 46 if(isset($_REQUEST['profile_name']) && $_REQUEST['profile_name'] != '') 47 $smarty->assign("PROFILE_NAME",$_REQUEST['profile_name']); 48 if(isset($_REQUEST['profile_description']) && $_REQUEST['profile_description'] != '') 49 $smarty->assign("PROFILE_DESCRIPTION",$_REQUEST['profile_description']); 50 if(isset($_REQUEST['mode']) && $_REQUEST['mode'] != '') 51 $smarty->assign("MODE",$_REQUEST['mode']); 52 53 $smarty->assign("MOD", return_module_language($current_language,'Settings')); 54 $smarty->assign("IMAGE_PATH",$image_path); 55 $smarty->assign("APP", $app_strings); 56 $smarty->assign("CMOD", $mod_strings); 57 58 $sql = "select * from vtiger_profile"; 59 $result = $adb->query($sql); 60 $profilelist = array(); 61 $temprow = $adb->fetch_array($result); 62 do 63 { 64 $name=$temprow["profilename"]; 65 $profileid=$temprow["profileid"]; 66 $profilelist[] = array($name,$profileid); 67 }while($temprow = $adb->fetch_array($result)); 68 $smarty->assign("PROFILE_LISTS", $profilelist); 69 70 $smarty->display("CreateProfile.tpl");
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sun Feb 25 10:22:19 2007 | par Balluche grâce à PHPXref 0.7 |