Jump to content

php problem


scoopy
 Share

Recommended Posts

Trying out a new webbased php program and the page loads up to this point and it prints this on the index page:

Fatal error: Cannot instantiate non-existent class: html_treenode in /var/www/html/Documentor/docbuilder/includes/utilities.php on line 52

Here's line 52 (and 53) from utilities.php file:

$node = new HTML_TreeNode(array('text' => basename(realpath($path)),'link'=> "",'icon' =>'folder.gif'));

The last time I ran into a similiar problem with another php program all I had to do was fix some quotes on the problem line... this time I can't find any thing from google to help me. I have a newer version of php than needed and other php stuff runs good on my box.

class HTML_TreeNode

is listed in the TreeMenu.php file and I believe this is the part of the index page that is not functioning.

 

Any ideas out there?

Link to comment
Share on other sites

If you don't find anything wrong within the code, email the author of that program reporting which is the error you've find and what you've done to force it. Doing that you'll get a fast fix and at the same time you'll be helping to develop that program

Link to comment
Share on other sites

A bug report on this has been filed more than a week ago now.

http://sourceforge.net/tracker/index.php?f...194&atid=111194

 

I would like to ask the users here (since I no nothing of php) does this line look like valid code? If so, any ideas why this line would cause this problem? If I had a better understanding of what it is expecting here, maybe I can find something more useful on another page and get this corected.

 

thanks

Link to comment
Share on other sites

I have no idea, I can't find it in the PHP manual so I have no clue what it's supposed to look like..

 

But from a pure syntax view it looks good, I suppose..

Link to comment
Share on other sites

Even though that is correct, I don't trust anything that isn't on php.net

 

Quite simply you're calling an non-existing class. If it was supposed to be included in PHP it would be on php.net, but I can't find it. (I haven't looked really hard, though) Either you have to make the class yourself or you'll have to find an alternate way to do what you want to do.

 

(Spell check the function, I've burned myself a couple of times by depending on my typing to much.)

Link to comment
Share on other sites

HTML_TreeNode appears to be part of the PEAR API. Do you have php-pear installed?

# rpm -qa | grep pear

php-pear-4.3.0-3mdk

 

I also found this:

 

http://pear.php.net/package-info.php?packa...e=HTML_TreeMenu

 

Once you get php-pear installed, run:

 

pear install HTML_TreeMenu

 

while connected to the net and it'll download and install it. That should help, maybe.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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.

Loading...
 Share

×
×
  • Create New...