forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 miscellaneous => Topic started by: Sandrina on March 16, 2014, 11:05:21 am

Title: Some issues with CpmFetch 2.0
Post by: Sandrina on March 16, 2014, 11:05:21 am
Hi.
My friend have some issues with her site ans ask me to help her with шею

She has 1.5.24 version of Coppermine Gallery and latest version of CpmFetch.

But she has next error when i trying to install CpmFetch:

Code: [Select]
Strict Standards: Declaration of cpm::debugPrint() should be compatible with cpm_dao::debugPrint() in /home/evansch/public_html/images/cpmfetch/cpmfetch.php on line 50
and

Code: [Select]
Deprecated: Function split() is deprecated in /home/evansch/public_html/images/cpmfetch/install.php on line 312
Site adress http://evans-chris.com/ (http://evans-chris.com/)

Can you help me to solve it? Thank you very much.
Title: Re: Some issues with CpmFetch 2.0
Post by: Sandrina on March 16, 2014, 12:20:38 pm
Problem is solved!) ;)
Title: Re: Some issues with CpmFetch 2.0
Post by: Sandrina on March 16, 2014, 12:25:16 pm
No, is normaly view only in Mozila Firefox. in Goggle Chrome is still have some errors.
Title: Re: Some issues with CpmFetch 2.0
Post by: phill104 on March 16, 2014, 04:07:59 pm
First, you should upgrade to 1.5.26 as this version has a security fix that should not be overlooked. It may even fix your problems. Having said that, strict standards errors are generated by your server as warnings. If they are now only showing in one browser and clear in the others then you probably have some cache switched on in that browser. Clear that and see if the error goes.

Also, please be aware that cpmfetch was never really released for CPG1.5.x and the version that you and many used is simply a quickly modified version which was designed for 1.4.x. We cannot fully support it as the chap who wrote it has not been around for quite some time, which is a real shame.
Title: Re: Some issues with CpmFetch 2.0
Post by: madaxeman on April 27, 2014, 11:19:16 pm
Not sure if this will help someone identify how to fix the 
Code: [Select]
Strict Standards: Declaration of cpm::debugPrint() should be compatible with cpm_dao::debugPrint() issue, however thought it might be relevant that I've got instances of cpmfetch running on different pages of my site .... some of which generate this error and some don't.

Where it doesn't seem to throw up the error message is here on my home page (http://www.madaxeman.com/index.php) which is in the root directory. The cpmfetch code here is:

Code: [Select]
<?php
 
include "./GALLERYDIRECTORY/cpmfetch/cpmfetch.php";
 
$objCpm = new cpm("./GALLERYDIRECTORY/cpmfetch/cpmfetch_config.php");
 
$objCpm->cpm_viewRandomMedia(1,3);  
 
$objCpm->cpm_viewLastAddedMedia(1,3);
 
$objCpm->cpm_close();
?>


But on other pages like this one (http://www.madaxeman.com/reports/Warfare_2009_1.php) which sits in a different subdirectory the error message appears the first time a new cpm is called. On this page (in the subdirectory) the cpmfetch code is like this:

Code: [Select]
<?php 
include "../GALLERYDIRECTORY/cpmfetch/cpmfetch.php";                                                      
$objCpm = new cpm("../GALLERYDIRECTORY/cpmfetch/cpmfetch_config.php");                                                      
$objCpm->cpm_viewRandomMediaFrom("album=17",1,6);                                                        
  
?>


Is that useful to anyone ?
Title: Re: Some issues with CpmFetch 2.0
Post by: madaxeman on May 03, 2014, 01:46:34 pm
I've now got a rather blunt-instrument work-around.

1. Create a "hidden" class in the site CSS
Code: [Select]
.hidden {
visibility: hidden;
display: none;
}

2. Call the first instance of cpmfetch on the page inside a div using the new hidden class
Code: [Select]
<div class="hidden">
<?php include "../PATHTOCPM/cpmfetch/cpmfetch.php";
  
$objCpm = new cpm("../PATHTOCPM/cpmfetch/cpmfetch_config.php");
  
?>

</div>


3. Use the called instance to drive subsequent image placements on the same page
Code: [Select]
<?php 
  $objCpm
->cpm_viewRandomMediaFrom("cat=2",1,5);  
  
?>

Then any unsolved error message is hidden in the hidden div, which also calls cpmfetch for the rest of the page
Title: Re: Some issues with CpmFetch 2.0
Post by: dellos on September 11, 2014, 02:13:05 pm
I'm using the CpmFetch 2.1.1 and last stable cpg 1.4 I'm getting some errors:

Strict Standards: Declaration of cpm::debugPrint() should be compatible with that of cpm_dao::debugPrint() in /home/.../cpmfetch/cpmfetch.php on line 50
Strict Standards: Only variables should be assigned by reference in /home/.../cpmfetch/cpmfetch.php on line 419

Is there some sollution for this ??
Title: Re: Some issues with CpmFetch 2.0
Post by: phill104 on September 11, 2014, 06:24:47 pm
Yes, upgrade to 1.5.x. We have not supported 1.4.x for quite some times hence that error will not be fixed, sorry.