forum.coppermine-gallery.net

Support => cpg1.4.x Support => Older/other versions => cpg1.4 plugins => Topic started by: pacimir on January 27, 2008, 10:53:00 am

Title: Problem: with PoTW plugin
Post by: pacimir on January 27, 2008, 10:53:00 am
I had to move my site to another hosting server and now I get an error in the Picture of the week plugin. It was working perfect before that. I guess the php version is newer in the new server and it's making that error. Any ideas how to solve the problem ?

Quote
Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 45

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 49

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 60

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 66

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 69

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 72

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 75

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 78

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 81

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 84

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 87

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 97

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 100

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 103

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 106

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 109

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 112

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/galeria/include/langfallback.inc.php on line 390

http://galeria.lukovit.com/plugins/potd/weekthumb.php

this is the source of weekthumb.php

Quote
<body bgcolor=#4b4b4b><?php
define('WEEKTHUMB_PHP', true);
define('IN_COPPERMINE', true);

require('include/init.inc.php');
global $prefix, $dbi;

$content = '';
{   
  $query = <<< EOT
    SELECT p.pid, aid, filepath, filename, owner_name, owner_id 
      FROM {$CONFIG['TABLE_PLUGIN_POTD']} AS pp LEFT JOIN {$CONFIG['TABLE_PICTURES']} AS p
      ON p.pid=pp.pid
    WHERE pp.potw='1'
EOT;
  $result = cpg_db_query($query, $dbi);
  $picture = mysql_fetch_array($result);
   $img = "<img src=\"{$CONFIG['path_to']}albums/{$picture['filepath']}thumb_{$picture['filename']}\"  border=\"0\">";
  $content .= <<< EOT
   <table bgcolor="#4b4b4b" align="center"><center><a href="{$CONFIG['path_to']}index.php?file=potd/week" target="_blank">$img</a></center></table>
EOT;
  $stop++;
}

print $content;
?>
Title: Re: Problem: with PoTW plugin
Post by: just_some_guy on January 27, 2008, 11:05:41 am
You are calling up the file incorrectly. This URL works http://galeria.lukovit.com/index.php?file=potd/weekthumb (http://galeria.lukovit.com/index.php?file=potd/weekthumb)

Notice the chage of the url, file = directory called "potd" and a file called "weekthumb" followed by an extension (it's being called by it's asset name).
Title: Re: Problem: with PoTW plugin
Post by: pacimir on January 27, 2008, 11:29:55 am
Thanks!
Works perfect with this link :)