Right, I managed to get those errors/debug information to come through and the whole thing is almost working - only problem is, its not updating the database now and it was before:
function update_db($new_filename)
{
// Get the PHP file containing the DbConnector class
require_once('../db/DbConnector.php');
// Create an instance of DbConnector
$connector = new DbConnector();
//===============================================
....
$product_id = $_GET['id'];
$_SESSION['errors'] .= "ID: ".$product_id."<br />";
if($new_filename != "")
{
// Update the database
if($featured != "YES")
{
if($connector->query("UPDATE store SET filename = '$new_filename', description = '$desc', item_name='$name', price = '$price', technology = '$tech', reference = '$ref', other_information = '$other' WHERE id='$product_id'"))
{
$_SESSION['errors'] .= "YES!";
}
$_SESSION['errors'] .= "Query is: "."UPDATE store SET filename = '$new_filename', item_name='$name', price = '$price', technology = '$tech', reference = '$ref', other_information = '$other' WHERE id='$product_id'"."<br />";
....
}
It shows the query as being perfect i.e. right id and all other information is fine.
I dont get any YES though therefore its not working.
In the first function I used the same code to do a select query and used require_once for the dbconnector script in both functions - maybe just includes? at the top of the page.
Any more question/code needed then say.
Cheers anyone