By Roel on Saturday, 22 August 2015
Posted in Technical Issues
Replies 5
Likes 0
Views 439
Votes 0
Hi,

You guys helped me with fixing index options in this thread:
http://stackideas.com/forums/smart-search-indexer-fails-with-unable-to-set-as-revision-as-current-revision-on-post

The indexer nicely runs to the end, but throws error an error:



Starting Indexer
Setting up Smart Search plugins
Setup 1070 items in 0.843 seconds.
* Processed batch 1 in 13.12 seconds.
* Processed batch 2 in 14.44 seconds.
* Processed batch 3 in 10.376 seconds.
* Processed batch 4 in 12.782 seconds.
* Processed batch 5 in 11.259 seconds.
* Processed batch 6 in 12.558 seconds.
* Processed batch 7 in 12.22 seconds.
PHP Notice: Undefined variable: resource in /home/vhosting/k/vhost0029082/domains/gillesen.nl/htdocs/nick/administrator/components/com_easyblog/includes/simpleimage/simpleimage.php on line 256

Notice: Undefined variable: resource in /home/vhosting/k/vhost0029082/domains/gillesen.nl/htdocs/nick/administrator/components/com_easyblog/includes/simpleimage/simpleimage.php on line 256
* Processed batch 8 in 11.964 seconds.
* Processed batch 9 in 8.607 seconds.
* Processed batch 10 in 4.998 seconds.
* Processed batch 11 in 5.093 seconds.
* Processed batch 12 in 5.45 seconds.
* Processed batch 13 in 5.406 seconds.
* Processed batch 14 in 5.827 seconds.
* Processed batch 15 in 4.957 seconds.
* Processed batch 16 in 5.372 seconds.
* Processed batch 17 in 5.328 seconds.
* Processed batch 18 in 3.458 seconds.
* Processed batch 19 in 0.475 seconds.
* Processed batch 20 in 0.313 seconds.
* Processed batch 21 in 0.476 seconds.
* Processed batch 22 in 0.194 seconds.
Total Processing Time: 155.525 seconds.



It seems harmless, but I'd like to know why this happens.

Line 256 is:



if ($this->type == IMAGETYPE_PNG) {

$resource = imagecreatetruecolor($width, $height);
$transparent = imagecolorallocatealpha($resource, 255, 255, 255, 127);

imagealphablending($resource, false);
imagesavealpha($resource, true);
imagefilledrectangle($resource, 0, 0, $width, $height, $transparent);
imagecopyresampled($resource, $this->resource, 0, 0, 0, 0, $width, $height, $this->getWidth(), $this->getHeight());
}

// Update with the new resource now
$this->resource = $resource;
}



Thank you,

Roel
Hello Roel,

Regarding your issue, look like there is a missing class property in that SimpleImage class I've added a fix on your site and can you give it a try again now? Below is the file I've modified at your site.

JOOMLA/administrator/components/com_easyblog/includes/simpleimage/simpleimage.php

The same fix will be added into next release of EasyBlog as well
Hope this help and have a nice day!
Sam
·
Monday, 24 August 2015 18:55
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Roel,

I am really sorry for the delay of this reply as it weekends for all of us here.

I've checked the code and I believe there are images on your site that are different in format (jpeg, gif and png) thus causing the error. Can I have your Joomla backend and FTP access so we can check on the issue further?
·
Monday, 24 August 2015 11:52
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Ezrul,

I've added the details in my profile.

Thanks,

Roel
·
Monday, 24 August 2015 18:42
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Sam,

It now runs without any issues.

Thank you!

Roel
·
Monday, 24 August 2015 19:17
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Roel,

You are most welcome. Glad that your issue now resolved
Have a nice day!
Sam
·
Monday, 24 August 2015 19:21
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post