Reputation: 83
I get this Error:
Message: The supplied parameters to Zend_Auth_Adapter_DbTable failed to produce a valid sql statement, please check table and column names for validity.
Public:
protected function _getAuthAdapter()
{
$dbAdapter = Zend_Db_Table::getDefaultAdapter();
$authAdapter = new Zend_Auth_Adapter_DbTable($dbAdapter);
$authAdapter->setTableName('users')
->setIdentityColumn('username')
->setCredentialColumn('password')
->setCredentialTreatment('SHA1(CONCAT(?,salt))');
return $authAdapter;
}
Tutorial from: http://akrabat.com/zend-auth-tutorial/
Upvotes: 0
Views: 1491
Reputation: 980
I believe the problem of the concatenated string, try this work over
->setCredentialTreatment("SHA1(CAST(CONCAT(?,salt) AS CHAR))");
Upvotes: 1