MySQL_DataBase MySQL_DataBase(
string
$host, string
$user, string
$db, string
$pass
)
|
|
MySQL_DataBase class constructor
Parameters:
string |
$host: |
|
string |
$user: |
|
string |
$db: |
|
string |
$pass: |
|
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
Function to connect to MySQL
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
resource DBPerform(
string
$table, array
$data, [string
$action = 'insert'], [string
$parameters = '']
)
|
|
Function to perform DB inserts and updates - abstracted from osCommerce-MS-2.2 project
Parameters:
string |
$table: |
Database table |
array |
$data: |
Associative array of columns / values |
string |
$action: |
insert or update |
string |
$parameters: |
|
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
array FetchArray(
resource
$resource_id, [string
$type = MYSQL_BOTH]
)
|
|
Function to fetch array
Parameters:
resource |
$resource_id: |
|
string |
$type: |
MYSQL_BOTH or MYSQL_ASSOC |
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
boolean Free(
resource
$resource_id
)
|
|
Function to free the resource
Parameters:
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
mixed NumRows(
resource
$resource_id
)
|
|
Function to fetch the number of rows
Parameters:
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
resource Query(
string
$query
)
|
|
Function to perform queries
Parameters:
string |
$query: |
SQL statement |
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
Function to select the database
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |
string Slashes(
string
$data
)
|
|
Function to add slashes
Parameters:
Information Tags:
Version: | 1.0 |
Author: | Bobby Easland |