Member
Member
eclrgp   05-08-2022, 17:05
#1

Hello,
There are references to $Image in deprecated-functions.php in 1.6a which need to be changed to $Images

WARNING: Undefined variable $image in /var/www/html/ZenPhoto/zp-core/zp-extensions/deprecated-functions/deprecated-functions.php on line 408

getRandomImages called from zpB_getRandomImages (functions.php [102])

from include (home.php [24])

from include (index.php [9])

from include (index.php [128])

from index.php [80]


These are the changes to deprecated-functions.php


405c405
< &#36;potd = array('day' => time(), 'folder' => &#36;image->getAlbumName(), 'filename' => &#36;image->getName());


      &#36;potd = array('day' => time(), 'folder' => &#36;images->getAlbumName(), 'filename' => &#36;images->getName());

408c408
< return &#36;image;


  return &#36;images;

Ray

Administrator
Administrator
acrylian   05-08-2022, 17:19
#2

We can fix that but actually you should fix the usage of deprecated function itself and use the recommended replacement instead. The plugin itself will also be deprecated in the final 1.6.

Member
Member
eclrgp   08-08-2022, 17:54
#3

I agree but I wanted to try using the zpBootstrap theme but keeping the number of fixes to it to a minimum

Administrator
Administrator
acrylian   08-08-2022, 18:01
#4

I understand. It is deprecated since 1.5.8. At some time it will have to be fixed.

It should be fixed now.

Member
Member
eclrgp   08-08-2022, 18:25
#5

Thank you. I see you have not changed &#36;image to &#36;images in line 405

Administrator
Administrator
acrylian   09-08-2022, 06:57
#6

Yes, you are right, was a quick fix inbetween just looking at the error line above, with a plain text editor that does not notify on unused vars. Should be fixed now.

Member
Member
eclrgp   09-08-2022, 09:29
#7

Thank you again

  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.