Update of /cvsroot/phpvortex/phpvortex/test
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv795/test
Modified Files:
.htaccess README.txt vortex_test.php vortex_test_page.php
Added Files:
conf.php
Log Message:
Test programs: Moved the DB configuration to an external file, for easier maintenance
--- NEW FILE: conf.php ---
<?php
/**
* Configuration file for the Test programs.
*
* @package Vortex
* @subpackage Debug
* @author Thiago Ramon Gonçalves Montoya
* @copyright Copyright 2004, Thiago Ramon Gonçalves Montoya
* @license http://opensource.org/licenses/lgpl-license.php GNU Lesser General Public License
*/
$db_connection = array(
'server' => 'localhost',
'db' => 'vortex_test',
'user' => 'root',
'pw' => ''
);
?>
Index: vortex_test_page.php
===================================================================
RCS file: /cvsroot/phpvortex/phpvortex/test/vortex_test_page.php,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** vortex_test_page.php 8 Oct 2004 17:17:24 -0000 1.5
--- vortex_test_page.php 10 Oct 2004 03:03:47 -0000 1.6
***************
*** 16,19 ****
--- 16,21 ----
/** Require the header for SEC_Page functionality. */
require_once('../SEC_Page.class.php');
+ /** Require the default configuration header. */
+ require_once('conf.php');
/**
***************
*** 44,48 ****
}
! $db =& new DB_MySQL(array('server' => 'localhost', 'db' => 'vortex_test', 'user' => 'root', 'pw' => ''));
$db->Connect();
--- 46,50 ----
}
! $db =& new DB_MySQL($db_connection);
$db->Connect();
Index: vortex_test.php
===================================================================
RCS file: /cvsroot/phpvortex/phpvortex/test/vortex_test.php,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** vortex_test.php 7 Oct 2004 21:26:44 -0000 1.11
--- vortex_test.php 10 Oct 2004 03:03:47 -0000 1.12
***************
*** 16,19 ****
--- 16,21 ----
/** Require the header for the Test Table class. */
require_once('TB_Test.class.php');
+ /** Require the default configuration header. */
+ require_once('conf.php');
?>
***************
*** 27,31 ****
<body>
<?php
! $db =& new DB_MySQL(array('server' => 'localhost', 'db' => 'vortex_test', 'user' => 'root', 'pw' => ''));
$db->Connect();
$tb =& new TB_Test($db);
--- 29,33 ----
<body>
<?php
! $db =& new DB_MySQL($db_connection);
$db->Connect();
$tb =& new TB_Test($db);
Index: README.txt
===================================================================
RCS file: /cvsroot/phpvortex/phpvortex/test/README.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** README.txt 8 Oct 2004 18:49:23 -0000 1.2
--- README.txt 10 Oct 2004 03:03:47 -0000 1.3
***************
*** 4,9 ****
2 - Execute the vortex_test.sql in your database server (only MySQL supported for now).
It will create a vortex_test database, and some test tables.
! 3 - If your server does't use .htaccess files, configure it to set the PHP include directory to your PHP Vortex folder.
! 4 - Change server and username/password to the database server in the test files if you use something more restricting than a 'root'/'' setup.
5 - Browse to the dir /test and see it working. Add a "?debug=3" in the URL for some cool debug info, if the debug headers are being included (see the .htaccess file).
6 - If something went wrong, send us a message with the problem and we will try to figure out what happened.
\ No newline at end of file
--- 4,9 ----
2 - Execute the vortex_test.sql in your database server (only MySQL supported for now).
It will create a vortex_test database, and some test tables.
! 3 - If your server does't use .htaccess files, configure it append and prepend the debug headers (see the .htaccess file).
! 4 - Change server and username/password to the database server in the conf.php file if you use something more restricting than a 'root'/'' setup.
5 - Browse to the dir /test and see it working. Add a "?debug=3" in the URL for some cool debug info, if the debug headers are being included (see the .htaccess file).
6 - If something went wrong, send us a message with the problem and we will try to figure out what happened.
\ No newline at end of file
Index: .htaccess
===================================================================
RCS file: /cvsroot/phpvortex/phpvortex/test/.htaccess,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** .htaccess 30 Sep 2004 20:46:54 -0000 1.1
--- .htaccess 10 Oct 2004 03:03:47 -0000 1.2
***************
*** 1,3 ****
! php_value include_path ".;.."
! php_value auto_prepend_file "d_header.php"
! php_value auto_append_file "d_footer.php"
\ No newline at end of file
--- 1,2 ----
! php_value auto_prepend_file "../d_header.php"
! php_value auto_append_file "../d_footer.php"
\ No newline at end of file
|