Web lists-archives.com

[PHP] Problem with mysqli_bind_param

I don't know if its a bug, a feature or just me being idiotic ( i don't
really discarded that yet )... but...

This is a small piece of my code.

        if ( !empty( $types )) {
            $tmp = Array( $types );
            foreach( $array as $key => $value ) {
                $tmp[] = &$array[ $key];

            call_user_func_array( array( $stmt, 'bind_param' ), $tmp );

My problem was i get NULL on return of call_user_func_array... i tracked it
back to $stmt->bind_param( $types, $array[0], $array[1], $array[2] );

Then after all and some reading i found i was screwing up, yet, returning
null should be the right return?

I ask because it says nothing about NULL on
http://php.net/manual/en/mysqli-stmt.bind-param.php. Yet if i send
something that isn't a string in $types ( my screw up, anyway ) it don't
return false as i expected.

Diogo Neves