Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
PHP-MySQLi-Database-Class
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
PHP-MySQLi-Database-Class
Commits
9ced1931
Commit
9ced1931
authored
Nov 02, 2010
by
Josh Campbell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated docs
parent
79b3bd45
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
7 deletions
+5
-7
MysqliDb.php
MysqliDb.php
+5
-7
No files found.
MysqliDb.php
View file @
9ced1931
...
...
@@ -6,7 +6,7 @@
* @package MysqliDB
* @author Jeffery Way <jeffrey@jeffrey-way.com>
* @author Josh Campbell <jcampbell@ajillion.com>
* @copyright Copyright (c) 2010
Jeffery Way
* @copyright Copyright (c) 2010
* @license http://opensource.org/licenses/gpl-3.0.html GNU Public License
* @version 1.1
**/
...
...
@@ -53,7 +53,7 @@ class MysqliDB {
*
* @var array
*/
protected
$_bindParams
=
array
(
''
);
protected
$_bindParams
=
array
(
''
);
// Create the empty 0 index
public
function
__construct
(
$host
,
$username
,
$password
,
$db
)
{
$this
->
_mysqli
=
new
mysqli
(
$host
,
$username
,
$password
,
$db
)
...
...
@@ -83,7 +83,7 @@ class MysqliDB {
protected
function
reset
()
{
$this
->
_where
=
array
();
$this
->
_bindParams
=
array
(
''
);
$this
->
_bindParams
=
array
(
''
);
// Create the empty 0 index
unset
(
$this
->
_query
);
unset
(
$this
->
_whereTypeList
);
unset
(
$this
->
_paramTypeList
);
...
...
@@ -102,7 +102,7 @@ class MysqliDB {
$stmt
=
$this
->
_prepareQuery
();
if
(
gettype
(
$bindParams
)
===
'array'
)
{
$params
=
array
(
''
);
$params
=
array
(
''
);
// Create the empty 0 index
foreach
(
$bindParams
as
$prop
=>
$val
)
{
$params
[
0
]
.=
$this
->
_determineType
(
$val
);
array_push
(
$params
,
&
$bindParams
[
$prop
]);
...
...
@@ -350,7 +350,7 @@ class MysqliDB {
foreach
(
$this
->
_where
as
$prop
=>
$val
)
{
array_push
(
$this
->
_bindParams
,
&
$this
->
_where
[
$prop
]);
}
}
}
}
// Bind parameters to statment
if
(
$hasTableData
||
$hasConditional
){
...
...
@@ -390,7 +390,6 @@ class MysqliDB {
return
$results
;
}
/**
* Method attempts to prepare the SQL query
* and throws an error if there was a problem.
...
...
@@ -403,7 +402,6 @@ class MysqliDB {
return
$stmt
;
}
public
function
__destruct
()
{
$this
->
_mysqli
->
close
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment