Jump to content

This code is php 4?


Monkuar

Recommended Posts

For some reason this stupid code is bringing up a white blank WSOD, no apache logs or nothing, running php 5 on my server.

 

function fetch_row($query_id = "") {
    
    	if ($query_id == "")
    	{
    		$query_id = $this->query_id;
    	}
    	
        $this->record_row = mysql_fetch_array($query_id, MYSQL_ASSOC) ;
        
        return $this->record_row;
        
    }

 

How can I make this php5 compatible? Thank you

Link to comment
Share on other sites

The only PHP function that code is mysql_fetch_array and that function works in both PHP4 and PHP5. So, it is already compatible for PHP5.

 

http://php.net/manual/en/function.mysql-fetch-array.php

 

Okay, Sorry I think I might have gave the wrong information, I am still getting WSOD though, and I get no apache error logs, or nothing.  Really making me eager to learn more about this php.

 

Link to comment
Share on other sites

The only PHP function that code is mysql_fetch_array and that function works in both PHP4 and PHP5. So, it is already compatible for PHP5.

 

http://php.net/manual/en/function.mysql-fetch-array.php

 

This is partially incorrect. PHP5 is no longer bundled with MySQL - that doesn't mean it wasn't enabled when PHP was built.

http://www.php.net/manual/en/faq.databases.php#faq.databases.mysql.php5

 

Again though, this would throw an error message, which would probably be found using requinix's solution.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.