I fixed the problem! For those who also encounter this problem, there was an error with the sql statement that pulls the user's information. I had to edit the following file:
includes/modules/pages/ask_a_question/header_php.php
At the very top, I change the if statement from:
Code:
if (!$_SESSION['customer_id'] && (ALLOW_GUEST_TO_ASK_A_QUESTION == 'false')) {
$_SESSION['navigation']->set_snapshot();
zen_redirect(zen_href_link(FILENAME_LOGIN, '', 'SSL'));
}
to:
Code:
if (!$_SESSION['customer_id'] && (ALLOW_GUEST_TO_ASK_A_QUESTION != 'true')) {
$_SESSION['navigation']->set_snapshot();
zen_redirect(zen_href_link(FILENAME_LOGIN, '', 'SSL'));
}
Later down in the code I changed the first customer_id sql statement from:
Code:
$sql = "SELECT customers_id, customers_firstname, customers_lastname, customers_password, customers_email_address, customers_default_address_id
FROM " . TABLE_CUSTOMERS . "
WHERE customers_id = :customersID";
$sql = $db->bindVars($sql, ':customersID', $_SESSION['customer_id'], 'integer');
to:
Code:
$sql = "SELECT customers_id, customers_firstname, customers_lastname, customers_password, customers_email_address, customers_default_address_id
FROM " . TABLE_CUSTOMERS . "
WHERE customers_id = " . (int)$_SESSION['customer_id'] . "";
Then the next customer_id sql statement I changed from:
Code:
$sql = "SELECT customers_id, customers_firstname, customers_lastname, customers_password, customers_email_address, customers_default_address_id
FROM " . TABLE_CUSTOMERS . "
WHERE customers_id = :customerID";
to:
Code:
$sql = "SELECT customers_id, customers_firstname, customers_lastname, customers_password, customers_email_address, customers_default_address_id
FROM " . TABLE_CUSTOMERS . "
WHERE customers_id = " . (int)$_SESSION['customer_id'] . "";
Uploaded the file to the server and was good to go. Of course, this assumes you are using the 1.3 version of the module and with PHP 5 and MySQL 5.
I hope that helps someone!
Bookmarks