Hi is there a simple solution here, other than reverting to php4? An upgrade from php5 to php5 has resulted in an error msg in this line: if( strlen($db_res ) > 0 ) { I understand this is bec. php5 is object orientated. It says an Object of class DB_result could not be converted to a string This is the full function: function pbcs_db_query( $q , $die_on_error=true, $ext_db_handle="" ) { global $db_handle; global $db_res; global $query_logging,$PHP_SELF; global $short_query_cache,$short_query_caching; if( $ext_db_handle == "" ) $query_db_handle = $db_handle; else $query_db_handle = $ext_db_handle; if( $short_query_caching && strlen( $q ) < 80 ) { $db_res = $short_query_cache[str_replace(" ","",$q)]; if( strlen($db_res ) > 0 ) { //do_log("object.log","READ: ".$db_res); // $db_res->resetResultSet( 0 ); mysql_data_seek( $db_res->result , 0 ); //do_log("query.log",$PHP_SELF." - FROM-CACHE - ".$q); return $db_res; } } Thanks Michael -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php