Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: Fatal error: Class 'cpm' not found in...  (Read 7797 times)

0 Members and 1 Guest are viewing this topic.

cornelp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Fatal error: Class 'cpm' not found in...
« on: September 30, 2006, 07:22:36 pm »

Hi. I installed the CPM Fetch and did a test. Everything passed just fine and no issues. When I try to display the images WITHIN my SMF Forums, I get an error message:

Fatal error: Class 'cpm' not found in /home/poserpac/public_html/forums/Sources/Load.php(1702) : eval()'d code on line 627

Line 627 in the index file for the forums is:

$objCpm = new cpm("/gallery");

Here is my info:

The test link: http://gallery.poserpacks.com/cpmfetch/cftest.php

I am running latest Coppermine and latest SMF 1.1 RC3.

Here is the error page:
http://forums.poserpacks.com/index.php

And the code I am entering in the index file for the forums:

include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$objCpm->cpm_viewRandomMedia(3,3);
$objCpm->cpm_close();

What am I doing wrong and what do I have to do to make it work? I have tried to search for that error, but no results. I have followed the instructions as described in the docs files.

Thank you...
Cornelp
Logged

Nibbler

  • Guest
Re: Fatal error: Class 'cpm' not found in...
« Reply #1 on: September 30, 2006, 07:39:48 pm »

Quote
include "./cpmfetch/cpmfetch.php";

That's not the right path.

You are here: /home/poserpac/public_html/forums/
You want to be here: /home/poserpac/public_html/gallery/cpmfetch/cftest.php

So the path is: ../gallery/cpmfetch/cftest.php
Logged

cornelp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Re: Fatal error: Class 'cpm' not found in...
« Reply #2 on: September 30, 2006, 07:51:21 pm »

I thank you for that. I guess Ive been at it too long to see it, but why am I getting an error where it says cpmfetch.php nout found in same directory? I uploaded all the files necessary to the same place.

So when I go to the http://forums.poserpacks.com/index.php

I get error 25, 30 , 80

But yet when I goto http://gallery.poserpacks.com/cpmfetch/cftest.php

Everything passes just fine.

???? I dont understand that part?

Thank you again for your help.
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: Fatal error: Class 'cpm' not found in...
« Reply #3 on: October 01, 2006, 02:04:19 am »

I thank you for that. I guess Ive been at it too long to see it, but why am I getting an error where it says cpmfetch.php nout found in same directory? I uploaded all the files necessary to the same place.

So when I go to the http://forums.poserpacks.com/index.php

I get error 25, 30 , 80

But yet when I goto http://gallery.poserpacks.com/cpmfetch/cftest.php

Everything passes just fine.

???? I dont understand that part?

Thank you again for your help.

The cftest.php has the include statement coded to expect the cpmfetch.php and cpmfetch_dao.php in the same directory.  If you want it to work elsewhere you need to change the include line.  Unless the rest of the stuff is also in the same directory.



Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco
Pages: [1]   Go Up
 

Page created in 0.036 seconds with 20 queries.