cfimageget.php delivers broken image cfimageget.php delivers broken image
 

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

Main Menu

cfimageget.php delivers broken image

Started by Jared5755, May 04, 2009, 06:23:42 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Jared5755

My main goal is to display an image on my phpBB index page.  I've tried displaying it the normal way (with the php function calls described in docs), but can't seem to get it displayed on my forums.  My test page works...where all I do is display a few random images from my gallery.  So, cpmFetch is working it appears.

So, now I'm trying to go the route of using cfimageget.php to display the image.  I am first trying just a test page that should only display 1 random image from my gallery.  But, all it's displaying is a broken image.

Test page:
Quote<img src="../gal/cpmfetch/cfimageget.php" />

Link to gallery:
Quotehttp://freeridelounge.net/gal/

First part of cfimageget.php:
Quoterequire_once "cpmfetch_dao.php";

// CHANGE THIS TO TRUE IF PEOPLE ARE ALLOWED QUERIES THROUGH HERE
$ALLOW_DIRECT_ACCESS = true;

if ($ALLOW_DIRECT_ACCESS && substr($_SERVER['SCRIPT_FILENAME'],-14) == "cfimageget.php") {
   
// This one you need to adjust unless your galler is at http://www.youname.com/photos
// If you installed right to the root of your web site, just use a /
// TODO This should be path to config file
$urltocpm = "../gal/";
$pathToConfigFile = "../gal/cpmfetch/";

// If no cmd= is submitted, it will do this:   
   $default_command = "random";


fangweile

I have the same problem a long time ago and i used this as a fix for my problem.

I extracted cfimageget.php from the copperminefetch-2.1.1-dev and overwrite the cfimageget.php from v. 2.0 and it works like a charm.
No need to edit any code from file.

Download the attached file cfimageget.txt (change the extension to .php) and upload it to your galleryroot/cpmfetch/ directory.
Then visit that page  http://freeridelounge.net/gal/cpmfetch/cfimageget.php
If the image appears, you will now start embedding random pictures in html tag.

Hope that it will work for you too.

Enjoy
[My Coppermine Galleries]
All Koreans, Lim Eun-kyeong's IFC
Saranghae 김태희

Jared5755

Thanks a lot!  Will try it out when I get back in town.