I'm guessing the bind_param
function you are calling is mysqli's bind_param.
If we have a look at the definition for this function we will see the variables are passed by reference:
bool mysqli_stmt::bind_param ( string $types , mixed &$var1 [, mixed &$... ] )
(The &
indicates by reference.)
Now let's look at the error you are getting:
Only variables should be passed by reference
The problem is that you are passing the results of function calls directly to bind_param
, when only variables should be passed by reference.
To get around this all you need to do is assign these values to variables and pass those to the function instead, for example:
$id = $this->auth->getInformation("id");
...
$stmt->bind_param('iissds', $id, ...
For more information on references take a look at the php.net article 'What References Do':
http://php.net/manual/en/language.references.whatdo.php
Hididng Errors
In your question you mention hiding these messages. It is always better to fix problems with your code than to suppress warnings.
To adjust what errors are displayed take a look at PHP's error_reporting
function.
If you wanted to show everything except strict you could do:
error_reporting(E_ALL ^ E_STRICT);
This can also be set in the php.ini configuration file:
error_reporting = E_ALL ^ E_STRICT