Bug #517 [Csd]: Fatal error: Call to a member function on a non-object in /usr/lib/php/Net/Whoi
| From: | mj@php.net | Date: | Sun, 29 Aug 2004 15:57:58 +0000 |
| Subject: | Bug #517 [Csd]: Fatal error: Call to a member function on a non-object in /usr/lib/php/Net/Whoi | ||
| References: | 1 | Groups: | php.pear.doc |
| Request: | Send a blank email to pear-doc+get-4800@lists.php.net to get a copy of this message | ||
Edit report at http://pear.php.net/bugs/bug.php?id=517&edit=1
ID: 517
Updated by: mj@php.net
Reported By: david dot rech at virusmedia dot de
Status: Closed
Type: Bug
Package: Documentation
Operating System: Gentoo Linux
PHP Version: 4.3.3
Assigned To: svenasse
New Comment:
The code example works for me with Net_Whois 1.0. What is the output
of
var_dump($data);
?
Previous Comments:
------------------------------------------------------------------------
[2004-08-29 11:51:25] pear at netergy dot com
I enter the code below and all I get is a page
displaying:
Object
and nothing else. How do I get the contents of the whois
displayed?
------------------------------------------------------------------------
[2004-02-16 04:10:25] lsmith at php dot net
This bug has been fixed in CVS.
In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on pear.php.net.
In case this was a pear.php.net website problem, the change will show
up on the website in short time.
Thank you for the report, and for helping us make PEAR better.
should be fixed when the documentation regenerates next sunday
------------------------------------------------------------------------
[2004-01-23 04:59:13] pminnieur at entwickler dot com
Jep, if you create the Net_Whois Object first, and use query() as a
method of this Object, it's OK. If you call it staticly, it'll fail.
------------------------------------------------------------------------
[2004-01-14 15:38:01] adam at trachtenberg dot com
This is a bug in the documentation, the correct usage of
Net_Whois is:
require_once "Net/Whois.php";
$server = "whois.denic.de";
$query = "phpcrawler.de"; // get information about
// this domain
$whois = new Net_Whois;
$data = $whois->query($query, $server);
echo $data;
------------------------------------------------------------------------
[2004-01-04 08:18:08] david dot rech at virusmedia dot de
Description:
------------
There seems to be a bug in Net_Whois. I've just reproduced it on two
diferrent machines. Both apache2, one Gentoo Linux und one RedHat 9.0.
While trying to execute your example, I've messed up with sice *nice*
message:
Fatal error: Call to a member function on a non-object in
/usr/lib/php/Net/Whois.php on line 131
Something might be wrong with the Net_Whois::_connect(), but is isn't?
Just weird.
Reproduce code:
---------------
<?php
require_once "Net/Whois.php";
$server = "whois.denic.de";
$query = "phpcrawler.de"; // get information about
// this domain
$data = Net_Whois::query($query, $server);
echo $data;
?>
Expected result:
----------------
Should return an Pear_Error or the reply of the whois server.
------------------------------------------------------------------------
--
Edit this bug report at http://pear.php.net/bugs/bug.php?id=517&edit=1