Warning Error Division by Zero on agHelper.php

Admiror Gallery is free extension for Joomla! 1.6. Joomla! 1.7 and Joomla! 2.5 based websites. Admiror Gallery is all in one, a simple and instant solution for rendering image gallery from folder with images, but very flexible and adaptable.
Post Reply
Message
Author
DirkP
Posts: 1
Joined: Thu Mar 14, 2013 9:08 pm

Warning Error Division by Zero on agHelper.php

#1 Post by DirkP »

I am just starting to learn Joomla 2.5 Stable and was trying out the Admiror Gallery.
The import of the pictures was going okay, and I changed the default size of the thumbs within the settings.

When I now go to the Gallery Menu, I see above Album name the error warning as shown below.
Warning: Division by zero in C:\xampp\htdocs\MySite\plugins\content\admirorgallery\admirorgallery\classes\agHelper.php on line 360

It is only showing this the first time I am entering the Gallery Meu from the Home of the Main Menu
As soon as I have clicked on the Albums and opened them and go back to the Gallery choose, the warning is gone.

I did open the agHelper.php and look at line 360. There it is calculating the height and width of the thumbs I beleave.
Looks like the first time one of the variables is zero. Is there a fix or can we have a look to set it on 1 then. ?

Does anyone have had this before ?

Kind regards
Dirk

Admiror Gallery 5 - Fundraising Campaign

User avatar
Vasiljevski
Developer
Developer
Posts: 1258
Joined: Sat Aug 14, 2010 9:31 pm
Location: Novi Sad, Serbia
Contact:

Re: Warning Error Division by Zero on agHelper.php

#2 Post by Vasiljevski »

There is a problem with you menu link.

Delete it and create a new menu link with the same settings.

Or check the link points to the correct item : index.php?option=com_admirorgallery&view=layout&Itemid=495

If your link is : index.php?option=com_admirorgallery&view=layout you will get the dividing error, because the layout cannot get the parameters because it it missing Itemid param.
Help Admiror Gallery become even better,
give us a review on JED

Post Reply