[Vtigercrm-developers] [vtiger-commits] r3869 - in /vtigercrm/branches/4.2: ./ cron/ database/ include/ include/database/ install/ modules/Calendar/
vtiger-commits at vtiger.fosslabs.com
vtiger-commits at vtiger.fosslabs.com
Tue Feb 21 11:53:00 PST 2006
Author: fathi
Date: Tue Feb 21 12:52:48 2006
New Revision: 3869
Log:
rename db_host_name and db_user_name to db_hostname and db_username
Modified:
vtigercrm/branches/4.2/config.inc.php
vtigercrm/branches/4.2/config.php
vtigercrm/branches/4.2/cron/intimateTaskStatus.php
vtigercrm/branches/4.2/database/DatabaseConnection.php
vtigercrm/branches/4.2/dbmonitor.php
vtigercrm/branches/4.2/include/backup.php
vtigercrm/branches/4.2/include/database/PearDatabase.php
vtigercrm/branches/4.2/index.php
vtigercrm/branches/4.2/install/2setConfig.php
vtigercrm/branches/4.2/install/3confirmConfig.php
vtigercrm/branches/4.2/install/4createConfigFile.php
vtigercrm/branches/4.2/install/config.template.php
vtigercrm/branches/4.2/modules/Calendar/config.php
Modified: vtigercrm/branches/4.2/config.inc.php
==============================================================================
--- vtigercrm/branches/4.2/config.inc.php (original)
+++ vtigercrm/branches/4.2/config.inc.php Tue Feb 21 12:52:48 2006
@@ -3,5 +3,5 @@
* The configuration file for FHS system
* is located at /etc/vtigercrm directory.
*/
- include('/etc/vtigercrm/config.inc.php');
+ include('config.inc.php');
?>
Modified: vtigercrm/branches/4.2/config.php
==============================================================================
--- vtigercrm/branches/4.2/config.php (original)
+++ vtigercrm/branches/4.2/config.php Tue Feb 21 12:52:48 2006
@@ -20,16 +20,16 @@
$H_NAME=gethostbyaddr($_SERVER['SERVER_ADDR']);
/* database configuration
- db_host_name: MySQL Database Hostname
- db_user_name: MySQL Username
- db_password: MySQL Password
- db_name: MySQL Database Name
+ db_hostname
+ db_username
+ db_password
+ db_name
*/
// all of these commented values get populated by install.php
-//$dbconfig['db_host_name'] = '$H_NAME.$sock_path';
-//$dbconfig['db_user_name'] = 'vtigercrm';
-//$dbconfig['db_password'] = '';
-//$dbconfig['db_name'] = 'vtigercrm';
+//$dbconfig['db_hostname'] = '$H_NAME.$sock_path';
+//$dbconfig['db_username'] = 'vtigercrm';
+//$dbconfig['db_password'] = '';
+//$dbconfig['db_name'] = 'vtigercrm';
//$host_name = '';
//$site_URL = '';
Modified: vtigercrm/branches/4.2/cron/intimateTaskStatus.php
==============================================================================
--- vtigercrm/branches/4.2/cron/intimateTaskStatus.php (original)
+++ vtigercrm/branches/4.2/cron/intimateTaskStatus.php Tue Feb 21 12:52:48 2006
@@ -2,9 +2,10 @@
require('send_mail.php');
require_once('../config.php');
-$dbhost = $dbconfig['db_host_name'];
-$dbuser =$dbconfig['db_user_name'];
+$dbhost = $dbconfig['db_hostname'];
+$dbuser = $dbconfig['db_username'];
$dbpass = $dbconfig['db_password'];
+
$db = mysql_connect($dbhost, $dbuser, $dbpass) or die ('Error connecting to mysql');
if (!$db) {
die('Could not connect: ' . mysql_error());
Modified: vtigercrm/branches/4.2/database/DatabaseConnection.php
==============================================================================
--- vtigercrm/branches/4.2/database/DatabaseConnection.php (original)
+++ vtigercrm/branches/4.2/database/DatabaseConnection.php Tue Feb 21 12:52:48 2006
@@ -29,7 +29,7 @@
if(!isset($disable_persistent_connections) || $disable_persistent_connections == false)
{
- $this->connection = @mysql_pconnect($dbconfig['db_host_name'], $dbconfig['db_user_name'],
+ $this->connection = @mysql_pconnect($dbconfig['db_hostname'], $dbconfig['db_username'],
$dbconfig['db_password']);
}
@@ -37,10 +37,11 @@
if($this->connection == false)
{
// We were unable to connect with pconnect. Try connect
- $this->connection = mysql_connect($dbconfig['db_host_name'],
- $dbconfig['db_user_name'],
+ $this->connection = mysql_connect(
+ $dbconfig['db_hostname'],
+ $dbconfig['db_username'],
$dbconfig['db_password'])
- or die("Could not connect to server ".$dbconfig['db_host_name']." as ".$dbconfig['db_user_name'].".".mysql_error());
+ or die("Could not connect to server ".$dbconfig['db_hostname']." as ".$dbconfig['db_username'].".".mysql_error());
if($this->connection == false && !isset($disable_persistent_connections) || $disable_persistent_connections == false)
{
Modified: vtigercrm/branches/4.2/dbmonitor.php
==============================================================================
--- vtigercrm/branches/4.2/dbmonitor.php (original)
+++ vtigercrm/branches/4.2/dbmonitor.php Tue Feb 21 12:52:48 2006
@@ -12,10 +12,10 @@
include_once('config.php');
include_once('adodb/adodb.inc.php');
+session_start();
-session_start();
$conn = ADONewConnection($dbconfig['db_type']);
-$conn->Connect($dbconfig['db_host_name'],$dbconfig['db_user_name'],$dbconfig['db_password'],$dbconfig['db_name']);
+$conn->Connect($dbconfig['db_hostname'],$dbconfig['db_username'],$dbconfig['db_password'],$dbconfig['db_name']);
$perf =& NewPerfMonitor($conn);
$perf->UI($pollsecs=5);
Modified: vtigercrm/branches/4.2/include/backup.php
==============================================================================
--- vtigercrm/branches/4.2/include/backup.php (original)
+++ vtigercrm/branches/4.2/include/backup.php Tue Feb 21 12:52:48 2006
@@ -11,8 +11,9 @@
require_once("config.php");
require_once("include/database/PearDatabase.php");
-define("dbserver", $dbconfig['db_host_name']);
-define("dbuser", $dbconfig['db_user_name']);
+
+define("dbserver", $dbconfig['db_hostname']);
+define("dbuser", $dbconfig['db_username']);
define("dbpass", $dbconfig['db_password']);
define("dbname", $dbconfig['db_name']);
Modified: vtigercrm/branches/4.2/include/database/PearDatabase.php
==============================================================================
--- vtigercrm/branches/4.2/include/database/PearDatabase.php (original)
+++ vtigercrm/branches/4.2/include/database/PearDatabase.php Tue Feb 21 12:52:48 2006
@@ -35,11 +35,8 @@
var $lastmysqlrow = -1;
var $enableSQLlog = false;
-
function isMySQL() { return dbType=='mysql'; }
-
function isOracle() { return dbType=='oci8'; }
-
function println($msg)
{
@@ -678,9 +675,9 @@
global $dbconfig, $dbconfigoption;
$this->disconnect();
$this->setDatabaseType($dbconfig['db_type']);
- $this->setUserName($dbconfig['db_user_name']);
+ $this->setUserName($dbconfig['db_username']);
$this->setUserPassword($dbconfig['db_password']);
- $this->setDatabaseHost( $dbconfig['db_host_name']);
+ $this->setDatabaseHost( $dbconfig['db_hostname']);
$this->setDatabaseName($dbconfig['db_name']);
$this->dbOptions = $dbconfigoption;
$this->enableSQLlog = ($dbconfig['log_sql'] == true);
@@ -711,9 +708,9 @@
{
$this->disconnect();
$this->setDatabaseType($dbconfig['db_type']);
- $this->setUserName($dbconfig['db_user_name']);
+ $this->setUserName($dbconfig['db_username']);
$this->setUserPassword($dbconfig['db_password']);
- $this->setDatabaseHost( $dbconfig['db_host_name']);
+ $this->setDatabaseHost( $dbconfig['db_hostname']);
$this->setDatabaseName($dbconfig['db_name']);
$this->dbOptions = $dbconfigoption;
if($dbconfig['log_sql'])
Modified: vtigercrm/branches/4.2/index.php
==============================================================================
--- vtigercrm/branches/4.2/index.php (original)
+++ vtigercrm/branches/4.2/index.php Tue Feb 21 12:52:48 2006
@@ -356,7 +356,7 @@
}
require_once('config.php');
-if (!isset($dbconfig['db_host_name'])) {
+if (!isset($dbconfig['db_hostname'])) {
header("Location: install.php");
exit();
}
Modified: vtigercrm/branches/4.2/install/2setConfig.php
==============================================================================
--- vtigercrm/branches/4.2/install/2setConfig.php (original)
+++ vtigercrm/branches/4.2/install/2setConfig.php Tue Feb 21 12:52:48 2006
@@ -68,19 +68,19 @@
global $dbconfig;
- if (isset($_REQUEST['db_host_name']))
- $db_host_name = $_REQUEST['db_host_name'];
- elseif (isset($dbconfig['db_host_name']))
- $db_host_name = $dbconfig['db_host_name'];
+ if (isset($_REQUEST['db_hostname']))
+ $db_hostname = $_REQUEST['db_hostname'];
+ elseif (isset($dbconfig['db_hostname']))
+ $db_hostname = $dbconfig['db_hostname'];
else
- $db_host_name = $H_NAME.$sock_path;
-
- if (isset($_REQUEST['db_user_name']))
- $db_user_name = $_REQUEST['db_user_name'];
- elseif (isset($dbconfig['db_user_name']))
- $db_user_name = $dbconfig['db_user_name'];
+ $db_hostname = $H_NAME.$sock_path;
+
+ if (isset($_REQUEST['db_username']))
+ $db_username = $_REQUEST['db_username'];
+ elseif (isset($dbconfig['db_username']))
+ $db_username = $dbconfig['db_username'];
else
- $db_user_name = $mysql_username;
+ $db_username = $mysql_username;
if (isset($_REQUEST['db_password']))
$db_password = $_REQUEST['db_password'];
@@ -126,8 +126,8 @@
$admin_password = $_REQUEST['admin_password'];
}
else {
- !isset($_REQUEST['db_host_name']) ? $db_host_name = $H_NAME.$sock_path : $db_host_name = $_REQUEST['db_host_name'];
- !isset($_REQUEST['db_user_name']) ? $db_user_name = $mysql_username : $db_user_name = $_REQUEST['db_user_name'];
+ !isset($_REQUEST['db_hostname']) ? $db_hostname = $H_NAME.$sock_path : $db_hostname = $_REQUEST['db_hostname'];
+ !isset($_REQUEST['db_username']) ? $db_username = $mysql_username : $db_username = $_REQUEST['db_username'];
!isset($_REQUEST['db_password']) ? $db_password= $mysql_password : $db_password = $_REQUEST['db_password'];
!isset($_REQUEST['db_name']) ? $db_name = "vtigercrm" : $db_name = $_REQUEST['db_name'];
!isset($_REQUEST['db_drop_tables']) ? $db_drop_tables = "0" : $db_drop_tables = $_REQUEST['db_drop_tables'];
@@ -170,16 +170,16 @@
var errorMessage = "";
// Here we decide whether to submit the form.
- if (trim(form.db_host_name.value) =='') {
+ if (trim(form.db_hostname.value) =='') {
isError = true;
errorMessage += "\n database host name";
- form.db_host_name.focus();
- }
-
- if (trim(form.db_user_name.value) =='') {
+ form.db_hostname.focus();
+ }
+
+ if (trim(form.db_username.value) =='') {
isError = true;
errorMessage += "\n database user name";
- form.db_user_name.focus();
+ form.db_username.focus();
}
if (trim(form.db_name.value) =='') {
@@ -296,11 +296,11 @@
<table width="80%" cellpadding="5" cellspacing="1" border="0" style="border: 1px dotted #666666;"><tbody>
<tr>
<td nowrap bgcolor="#F5F5F5" width="40%"><strong>Host Name</strong> <sup><font color=red>*</font></sup></td>
- <td align="left"><input type="text" class="dataInput" name="db_host_name" value="<?php if (isset($db_host_name)) echo "$db_host_name"; ?>" /></td>
+ <td align="left"><input type="text" class="dataInput" name="db_hostname" value="<?php if (isset($db_hostname)) echo "$db_hostname"; ?>" /></td>
</tr>
<tr>
<td nowrap bgcolor="#F5F5F5"><strong>User Name</strong> <sup><font color=red>*</font></sup></td>
- <td align="left"><input type="text" class="dataInput" name="db_user_name" value="<?php if (isset($db_user_name)) echo "$db_user_name"; ?>" /></td>
+ <td align="left"><input type="text" class="dataInput" name="db_username" value="<?php if (isset($db_username)) echo "$db_username"; ?>" /></td>
</tr>
<tr>
<td nowrap bgcolor="#F5F5F5"><strong>Password</strong> <sup><font color=red>*</font></sup></td>
Modified: vtigercrm/branches/4.2/install/3confirmConfig.php
==============================================================================
--- vtigercrm/branches/4.2/install/3confirmConfig.php (original)
+++ vtigercrm/branches/4.2/install/3confirmConfig.php Tue Feb 21 12:52:48 2006
@@ -17,11 +17,11 @@
* Description: Executes a step in the installation process.
********************************************************************************/
-if (isset($_REQUEST['db_host_name']))
- $db_host_name = $_REQUEST['db_host_name'];
-
-if (isset($_REQUEST['db_user_name']))
- $db_user_name = $_REQUEST['db_user_name'];
+if (isset($_REQUEST['db_hostname']))
+ $db_hostname = $_REQUEST['db_hostname'];
+
+if (isset($_REQUEST['db_username']))
+ $db_username = $_REQUEST['db_username'];
if (isset($_REQUEST['db_password']))
$db_password = $_REQUEST['db_password'];
@@ -76,7 +76,7 @@
$mysql_db_status = 'true';
}
else {
- $conn = @mysql_pconnect($db_host_name,$db_user_name,$db_password);
+ $conn = @mysql_pconnect($db_hostname,$db_username,$db_password);
if(!$conn)
$mysql_status = 'false';
else {
@@ -142,11 +142,11 @@
<table width="80%" cellpadding="5" border="0" style="border: 1px dotted #666666;"><tbody>
<tr>
<td bgcolor="#F5F5F5" width="40%">Host Name</td>
- <td align="left" nowrap>: <font class="dataInput"><?php if (isset($db_host_name)) echo "$db_host_name"; ?></font></td>
+ <td align="left" nowrap>: <font class="dataInput"><?php if (isset($db_hostname)) echo "$db_hostname"; ?></font></td>
</tr>
<tr>
<td bgcolor="#F5F5F5" width="40%">User Name</td>
- <td align="left" nowrap>: <font class="dataInput"><?php if (isset($db_user_name)) echo "$db_user_name"; ?></font></td>
+ <td align="left" nowrap>: <font class="dataInput"><?php if (isset($db_username)) echo "$db_username"; ?></font></td>
</tr>
<tr>
<td bgcolor="#F5F5F5" width="40%" noWrap>Password</td>
@@ -194,8 +194,8 @@
<td align="left" valign="bottom">
<form action="install.php" method="post" name="form" id="form">
<input type="hidden" name="file" value="2setConfig.php">
- <input type="hidden" class="dataInput" name="db_host_name" value="<?php if (isset($db_host_name)) echo "$db_host_name"; ?>" />
- <input type="hidden" class="dataInput" name="db_user_name" value="<?php if (isset($db_user_name)) echo "$db_user_name"; ?>" />
+ <input type="hidden" class="dataInput" name="db_hostname" value="<?php if (isset($db_hostname)) echo "$db_hostname"; ?>" />
+ <input type="hidden" class="dataInput" name="db_username" value="<?php if (isset($db_username)) echo "$db_username"; ?>" />
<input type="hidden" class="dataInput" name="db_password" value="<?php if (isset($db_password)) echo "$db_password"; ?>" />
<input type="hidden" class="dataInput" name="db_name" value="<?php if (isset($db_name)) echo "$db_name"; ?>" />
<input type="hidden" class="dataInput" name="db_drop_tables" value="<?php if (isset($db_drop_tables)) echo "$db_drop_tables"; ?>" />
@@ -227,8 +227,8 @@
<input type="checkbox" class="dataInput" name="db_populate" value="1">
- <input type="hidden" class="dataInput" name="db_host_name" value="<?php if (isset($db_host_name)) echo "$db_host_name"; ?>" />
- <input type="hidden" class="dataInput" name="db_user_name" value="<?php if (isset($db_user_name)) echo "$db_user_name"; ?>" />
+ <input type="hidden" class="dataInput" name="db_hostname" value="<?php if (isset($db_hostname)) echo "$db_hostname"; ?>" />
+ <input type="hidden" class="dataInput" name="db_username" value="<?php if (isset($db_username)) echo "$db_username"; ?>" />
<input type="hidden" class="dataInput" name="db_password" value="<?php if (isset($db_password)) echo "$db_password"; ?>" />
<input type="hidden" class="dataInput" name="db_name" value="<?php if (isset($db_name)) echo "$db_name"; ?>" />
<input type="hidden" class="dataInput" name="db_drop_tables" value="<?php if (isset($db_drop_tables)) echo "$db_drop_tables"; ?>" />
@@ -251,8 +251,8 @@
<!-- td align="right">
<form action="install.php" method="post" name="form" id="form">
<input type="hidden" name="file" value="4createConfigFile.php">
- <input type="hidden" class="dataInput" name="db_host_name" value="<?php if (isset($db_host_name)) echo "$db_host_name"; ?>" />
- <input type="hidden" class="dataInput" name="db_user_name" value="<?php if (isset($db_user_name)) echo "$db_user_name"; ?>" />
+ <input type="hidden" class="dataInput" name="db_hostname" value="<?php if (isset($db_hostname)) echo "$db_hostname"; ?>" />
+ <input type="hidden" class="dataInput" name="db_username" value="<?php if (isset($db_username)) echo "$db_username"; ?>" />
<input type="hidden" class="dataInput" name="db_password" value="<?php if (isset($db_password)) echo "$db_password"; ?>" />
<input type="hidden" class="dataInput" name="db_name" value="<?php if (isset($db_name)) echo "$db_name"; ?>" />
<input type="hidden" class="dataInput" name="db_drop_tables" value="<?php if (isset($db_drop_tables)) echo "$db_drop_tables"; ?>" />
@@ -338,11 +338,11 @@
<table width="70%" cellpadding="5" border="0" style="border: 1px dotted #666666;">
<tr>
<td bgcolor="#F5F5F5" width="40%">Host Name</td>
- <td align="left" nowrap><font class="dataInput"><?php if (isset($db_host_name)) echo "$db_host_name"; ?></font></td>
+ <td align="left" nowrap><font class="dataInput"><?php if (isset($db_hostname)) echo "$db_hostname"; ?></font></td>
</tr>
<tr>
<td bgcolor="#F5F5F5" width="40%">User Name</td>
- <td align="left" nowrap><font class="dataInput"><?php if (isset($db_user_name)) echo "$db_user_name"; ?></font></td>
+ <td align="left" nowrap><font class="dataInput"><?php if (isset($db_username)) echo "$db_username"; ?></font></td>
</tr>
<tr>
<td noWrap bgcolor="#F5F5F5" width="40%">Password</td>
@@ -359,8 +359,8 @@
<td align="right">
<form action="install.php" method="post" name="form" id="form">
<input type="hidden" name="file" value="2setConfig.php">
- <input type="hidden" class="dataInput" name="db_host_name" value="<?php if (isset($db_host_name)) echo "$db_host_name"; ?>" />
- <input type="hidden" class="dataInput" name="db_user_name" value="<?php if (isset($db_user_name)) echo "$db_user_name"; ?>" />
+ <input type="hidden" class="dataInput" name="db_hostname" value="<?php if (isset($db_hostname)) echo "$db_hostname"; ?>" />
+ <input type="hidden" class="dataInput" name="db_username" value="<?php if (isset($db_username)) echo "$db_username"; ?>" />
<input type="hidden" class="dataInput" name="db_password" value="<?php if (isset($db_password)) echo "$db_password"; ?>" />
<input type="hidden" class="dataInput" name="db_name" value="<?php if (isset($db_name)) echo "$db_name"; ?>" />
<input type="hidden" class="dataInput" name="db_drop_tables" value="<?php if (isset($db_drop_tables)) echo "$db_drop_tables"; ?>" />
@@ -429,8 +429,8 @@
<td height="40" align="right">
<form action="install.php" method="post" name="form" id="form">
<input type="hidden" name="file" value="2setConfig.php">
- <input type="hidden" class="dataInput" name="db_host_name" value="<?php if (isset($db_host_name)) echo "$db_host_name"; ?>" />
- <input type="hidden" class="dataInput" name="db_user_name" value="<?php if (isset($db_user_name)) echo "$db_user_name"; ?>" />
+ <input type="hidden" class="dataInput" name="db_hostname" value="<?php if (isset($db_hostname)) echo "$db_hostname"; ?>" />
+ <input type="hidden" class="dataInput" name="db_username" value="<?php if (isset($db_username)) echo "$db_username"; ?>" />
<input type="hidden" class="dataInput" name="db_password" value="<?php if (isset($db_password)) echo "$db_password"; ?>" />
<input type="hidden" class="dataInput" name="db_name" value="<?php if (isset($db_name)) echo "$db_name"; ?>" />
<input type="hidden" class="dataInput" name="db_drop_tables" value="<?php if (isset($db_drop_tables)) echo "$db_drop_tables"; ?>" />
Modified: vtigercrm/branches/4.2/install/4createConfigFile.php
==============================================================================
--- vtigercrm/branches/4.2/install/4createConfigFile.php (original)
+++ vtigercrm/branches/4.2/install/4createConfigFile.php Tue Feb 21 12:52:48 2006
@@ -27,11 +27,11 @@
$vtiger_version = "4.2.3";
$release_date = "23 December 2005";
-if (isset($_REQUEST['db_host_name']))
- $db_host_name = $_REQUEST['db_host_name'];
-
-if (isset($_REQUEST['db_user_name']))
- $db_user_name = $_REQUEST['db_user_name'];
+if (isset($_REQUEST['db_hostname']))
+ $db_hostname = $_REQUEST['db_hostname'];
+
+if (isset($_REQUEST['db_username']))
+ $db_username = $_REQUEST['db_username'];
if (isset($_REQUEST['db_password']))
$db_password = $_REQUEST['db_password'];
@@ -155,13 +155,13 @@
$config .= "\$HELPDESK_SUPPORT_NAME = 'your-domain name';\n";
$config .= "\n";
$config .= "/* database configuration\n";
-$config .= " db_host_name:MySQL Database Hostname\n";
-$config .= " db_user_name:MySQL Username\n";
+$config .= " db_hostname:MySQL Database Hostname\n";
+$config .= " db_username:MySQL Username\n";
$config .= " db_password:MySQL Password\n";
$config .= " db_name:MySQL Database Name\n";
$config .= "*/\n";
-$config .= "\$dbconfig['db_host_name'] = '".$db_host_name."';\n";
-$config .= "\$dbconfig['db_user_name'] = '".$db_user_name."';\n";
+$config .= "\$dbconfig['db_hostname'] = '".$db_hostname."';\n";
+$config .= "\$dbconfig['db_username'] = '".$db_username."';\n";
$config .= "\$dbconfig['db_password'] = '".$db_password."';\n";
$config .= "\$dbconfig['db_name'] = '".$db_name."';\n";
$config .= "\n";
@@ -189,7 +189,7 @@
$config .= "// ssl default value = false\n";
$config .= "\$dbconfigoption['ssl'] = false;\n";
$config .= "\n";
-$config .= "\$host_name = '".$db_host_name."';\n";
+$config .= "\$host_name = '".$db_hostname."';\n";
$config .= "\$site_URL = '".$site_URL."';\n";
$config .= "\$root_directory = '".$root_directory."';\n";
$config .= "\$cache_dir = '$cache_dir';\n";
@@ -306,8 +306,8 @@
$config .= "\n";
//$config .= "// forum configurations\n";
//$config .= "\$dbms = 'mysql';\n";
-//$config .= "\$dbhost = '".$db_host_name."';\n\n";
-//$config .= "\$dbuser = '".$db_user_name."';\n\n";
+//$config .= "\$dbhost = '".$db_hostname."';\n\n";
+//$config .= "\$dbuser = '".$db_username."';\n\n";
//$config .= "\$dbpasswd = '".$db_password."';\n\n";
//$config .= "\$dbname= '".$db_name."';\n\n";
//$config .= "\$table_prefix = 'phpbb_';\n";
@@ -337,8 +337,8 @@
<form action="install.php" method="post" name="form" id="form">
<input type="hidden" name="file" value="5createTables.php">
- <input type="hidden" class="dataInput" name="db_host_name" value="<?php if (isset($db_host_name)) echo "$db_host_name"; ?>" />
- <input type="hidden" class="dataInput" name="db_user_name" value="<?php if (isset($db_user_name)) echo "$db_user_name"; ?>" />
+ <input type="hidden" class="dataInput" name="db_hostname" value="<?php if (isset($db_hostname)) echo "$db_hostname"; ?>" />
+ <input type="hidden" class="dataInput" name="db_username" value="<?php if (isset($db_username)) echo "$db_username"; ?>" />
<input type="hidden" class="dataInput" name="db_password" value="<?php if (isset($db_password)) echo "$db_password"; ?>" />
<input type="hidden" class="dataInput" name="db_name" value="<?php if (isset($db_name)) echo "$db_name"; ?>" />
<input type="hidden" class="dataInput" name="db_drop_tables" value="<?php if (isset($db_drop_tables)) echo "$db_drop_tables"; ?>" />
Modified: vtigercrm/branches/4.2/install/config.template.php
==============================================================================
--- vtigercrm/branches/4.2/install/config.template.php (original)
+++ vtigercrm/branches/4.2/install/config.template.php Tue Feb 21 12:52:48 2006
@@ -34,18 +34,24 @@
$HELPDESK_SUPPORT_NAME = 'your-domain name';
/* database configuration
- db_host_name: MySQL Database Hostname
- db_user_name: MySQL Username
- db_password: MySQL Password
- db_name: MySQL Database Name
+ db_server
+ db_port
+ db_hostname
+ db_username
+ db_password
+ db_name
*/
-$dbconfig['db_host_name'] = 'localhost:80';
-$dbconfig['db_user_name'] = 'root';
-$dbconfig['db_password'] = '';
-$dbconfig['db_name'] = 'vtigercrm';
+
+$dbconfig['db_server'] = '_DBC_SERVER_';
+// TODO test if port is empty
+$dbconfig['db_port'] = ':_DBC_PORT_';
+$dbconfig['db_hostname'] = $dbconfig['db_server'].$dbconfig['db_port'];
+$dbconfig['db_username'] = '_DBC_USER_';
+$dbconfig['db_password'] = '_DBC_PASS_';
+$dbconfig['db_name'] = '_DBC_NAME_';
// db_type default value = mysql
-$dbconfig['db_type'] = 'mysql';
+$dbconfig['db_type'] = '_DBC_TYPE';
// log_sql default value = false
$dbconfig['log_sql'] = false;
@@ -68,9 +74,9 @@
// ssl default value = false
$dbconfigoption['ssl'] = false;
-$host_name = 'localhost:80';
-$site_URL = 'http://127.0.0.1:80/vtigercrm-4.2';
-$root_directory = '/var/www/vtigercrm-4.2/';
+$host_name = $dbconfig['db_hostname'];
+$site_URL = 'http://'.$dbconfig['db_server'].'/vtigercrm';
+$root_directory = '/var/www/vtigercrm';
$cache_dir = 'cache/';
$mail_server = '';
$mail_server_username = '';
@@ -101,7 +107,7 @@
$upload_badext = array('php', 'php3', 'php4', 'php5', 'pl', 'cgi', 'py', 'asp', 'cfm', 'js', 'vbs', 'html', 'htm');
// full path to include directory including the trailing slash
-// includeDirectory default value = /var/www/vtigercrm-4.2/.'include/
+// includeDirectory default value = /var/www/vtigercrm/.'include/
$includeDirectory = $root_directory.'include/';
// list_max_entries_per_page default value = 20
Modified: vtigercrm/branches/4.2/modules/Calendar/config.php
==============================================================================
--- vtigercrm/branches/4.2/modules/Calendar/config.php (original)
+++ vtigercrm/branches/4.2/modules/Calendar/config.php Tue Feb 21 12:52:48 2006
@@ -6,9 +6,9 @@
require_once 'config.php';
$tutos[demo]=0;
$tutos[dbname][0] = $dbconfig['db_name'];
-$tutos[dbhost][0] = $dbconfig['db_host_name'];
+$tutos[dbhost][0] = $dbconfig['db_hostname'];
$tutos[dbport][0] = 5000;
-$tutos[dbuser][0] = $dbconfig['db_user_name'];
+$tutos[dbuser][0] = $dbconfig['db_username'];
$tutos[dbpasswd][0] = $dbconfig['db_password'];
$tutos[dbtype][0] = 2;
$tutos[dbalias][0] = "MYSQL TEST database";
More information about the vtigercrm-developers
mailing list