adodb 최신버전으로 변경

<? 를 <?php 로 변경
This commit is contained in:
2018-01-11 19:28:35 +09:00
parent feff33715f
commit 7b3b674dee
450 changed files with 19425 additions and 32248 deletions
+22 -29
View File
@@ -1,24 +1,18 @@
<?php
//
// +----------------------------------------------------------------------+
// | PHP Version 4 |
// +----------------------------------------------------------------------+
// | |
// +----------------------------------------------------------------------+
// | This source file is subject to version 2.02 of the PHP license, |
// | that is bundled with this package in the file LICENSE, and is |
// | available at through the world-wide-web at |
// | http://www.php.net/license/2_02.txt. |
// | If you did not receive a copy of the PHP license and are unable to |
// | obtain it through the world-wide-web, please send a note to |
// | license@php.net so we can mail you a copy immediately. |
// +----------------------------------------------------------------------+
// | Authors: Martin Jansen <mj@php.net>
// | Richard Tango-Lowy <richtl@arscognita.com> |
// +----------------------------------------------------------------------+
//
// $Id: ADOdb.php,v 1.3 2005/05/18 06:58:47 jlim Exp $
//
/*
@version v5.20.9 21-Dec-2016
@copyright (c) 2000-2013 John Lim (jlim#natsoft.com). All rights reserved.
@copyright (c) 2014 Damien Regad, Mark Newnham and the ADOdb community
Released under both BSD license and Lesser GPL library license.
Whenever there is any discrepancy between the two licenses,
the BSD license will take precedence. See License.txt.
Set tabs to 4 for best viewing.
Latest version is available at http://adodb.sourceforge.net
Original Authors: Martin Jansen <mj#php.net>
Richard Tango-Lowy <richtl#arscognita.com>
*/
require_once 'Auth/Container.php';
require_once 'adodb.inc.php';
@@ -52,7 +46,7 @@ class Auth_Container_ADOdb extends Auth_Container
*/
var $db = null;
var $dsn = '';
/**
* User that is currently selected from the DB.
* @var string
@@ -69,10 +63,10 @@ class Auth_Container_ADOdb extends Auth_Container
* @param string Connection data or DB object
* @return object Returns an error object if something went wrong
*/
function Auth_Container_ADOdb($dsn)
function __construct($dsn)
{
$this->_setDefaults();
if (is_array($dsn)) {
$this->_parseOptions($dsn);
@@ -104,7 +98,7 @@ class Auth_Container_ADOdb extends Auth_Container
return PEAR::raiseError($err);
}
}
} else {
return PEAR::raiseError('The given dsn was not valid in file ' . __FILE__ . ' at line ' . __LINE__,
41,
@@ -113,7 +107,7 @@ class Auth_Container_ADOdb extends Auth_Container
null
);
}
if(!$this->db) {
return PEAR::raiseError(ADODB_Pear_error());
} else {
@@ -136,7 +130,7 @@ class Auth_Container_ADOdb extends Auth_Container
function _prepare()
{
if(!$this->db) {
$res = $this->_connect($this->options['dsn']);
$res = $this->_connect($this->options['dsn']);
}
return true;
}
@@ -242,11 +236,11 @@ class Auth_Container_ADOdb extends Auth_Container
else{
$sql_from = $this->options['usernamecol'] . ", ".$this->options['passwordcol'].$this->options['db_fields'];
}
$query = "SELECT ".$sql_from.
" FROM ".$this->options['table'].
" WHERE ".$this->options['usernamecol']." = " . $this->db->Quote($username);
$ADODB_FETCH_MODE = ADODB_FETCH_ASSOC;
$rset = $this->db->Execute( $query );
$res = $rset->fetchRow();
@@ -410,4 +404,3 @@ function dump( $var, $str, $vardump = false ) {
( !$vardump ) ? ( print_r( $var )) : ( var_dump( $var ));
print "</pre>";
}
?>