4.0 Alpha 3 - Creation error

Phoca Gallery - image gallery extension
AnGL
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 16 Jan 2013, 12:38

4.0 Alpha 3 - Creation error

Post by AnGL »

I try to use 4.0 alpha3 release for Joomla 3.0.2.
Then I try to create:

1. Image:
Warning: Invalid argument supplied for foreach() in /www/vhosts/.../administrator/components/com_phocagallery/views/phocagalleryimgs/view.html.php on line 32

2. Category:
500 SQL=SELECT a.*,l.title AS language_title,uc.name AS editor,ag.title AS access_level,c.title AS parentcat_title, c.id AS parentcat_id,ua.id AS userid, ua.username AS username, ua.name AS usernameno,v.average AS ratingavg,cc.countid AS countid FROM `jos_phocagallery_categories` AS a LEFT JOIN `jos_languages` AS l ON l.lang_code = a.language LEFT JOIN jos_users AS uc ON uc.id=a.checked_out LEFT JOIN jos_viewlevels AS ag ON ag.id = a.access LEFT JOIN jos_phocagallery_categories AS c ON c.id = a.parent_id LEFT JOIN jos_users AS ua ON ua.id = a.owner_id LEFT JOIN jos_phocagallery_votes_statistics AS v ON v.catid = a.id LEFT JOIN (SELECT cc.parent_id, count(*) AS countid FROM jos_phocagallery_categories AS cc GROUP BY cc.parent_id ) AS cc ON a.parent_id = cc.parent_id GROUP BY a.id ORDER BY

Do you have any idea to fix it?
Thank you
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49149
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: 4.0 Alpha 3 - Creation error

Post by Jan »

Hi, try to uninstall the gallery and reinstall, seems like there is some problem with phoca gallery tables in your database.
If you find Phoca extensions useful, please support the project
janne
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 20 Jan 2013, 18:27

Re: 4.0 Alpha 3 - Creation error

Post by janne »

Hi
I also have the exact same problems.
I have had it all time since alpha 1, I tried uninstall and delete the tables but nothing seems to work.
I think its something in the joomla setup, maybe the language.

Janne
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49149
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: 4.0 Alpha 3 - Creation error

Post by Jan »

Hmmm, really no idea what can be wrong there,

try to open:
administrator\components\com_phocagallery\models\phocagalleryimgs.php

and add:

Code: Select all

print_r($this->state->get('list.ordering'));
print_r($this->state->get('list.direction'));
before:

Code: Select all

$query->order($db->escape($orderCol.' '.$orderDirn));
cca line 186

You should get: a.titleasc (a.title asc) string at the top of the site (under the menu). If not, then there is something wrong with states in your Joomla! :idea:
If you find Phoca extensions useful, please support the project
janne
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 20 Jan 2013, 18:27

Re: 4.0 Alpha 3 - Creation error

Post by janne »

I added the rows to phocagallerycs.php and when I enter the category form I get a.titleasc just under the menu.
I dont know if this test is good enough but it seems like the state is OK.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49149
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: 4.0 Alpha 3 - Creation error

Post by Jan »

Hi, this means, in such case you cannot get empty "ORDER BY ..." but "ORDER BY a.title asc"

Do you still get the error message with the sql query? If yes, try to copy the query and add it to sql query window in your phpmyadmin, maybe you will get more information about the problem :idea:

Jan
If you find Phoca extensions useful, please support the project
janne
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 20 Jan 2013, 18:27

Re: 4.0 Alpha 3 - Creation error

Post by janne »

Sorry Jan but I still get the error and I have copied the query and tried it in phpmyadmin.
The select works if I get rid of the empty ORDER BY

I mailed you earlier about this but I haven’t found any solution for the empty ORDER BY.
AnGL
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 16 Jan 2013, 12:38

Re: 4.0 Alpha 3 - Creation error

Post by AnGL »

Jan wrote:Hmmm, really no idea what can be wrong there,

try to open:
administrator\components\com_phocagallery\models\phocagalleryimgs.php

and add:

Code: Select all

print_r($this->state->get('list.ordering'));
print_r($this->state->get('list.direction'));
before:

Code: Select all

$query->order($db->escape($orderCol.' '.$orderDirn));
cca line 186

You should get: a.titleasc (a.title asc) string at the top of the site (under the menu). If not, then there is something wrong with states in your Joomla! :idea:

Thank you, but it doesn't help
AnGL
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 16 Jan 2013, 12:38

Re: 4.0 Alpha 3 - Creation error

Post by AnGL »

Jan wrote:Hi, try to uninstall the gallery and reinstall, seems like there is some problem with phoca gallery tables in your database.
It doesn't help too. I tried to unstall and delete tables from MySQL admin ...
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49149
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: 4.0 Alpha 3 - Creation error

Post by Jan »

Hi, I made some changes in controller so maybe this help, please wait until the gallery will be Beta. Then please test it and let me know (I hope I will finish the Beta soon)

Jan
If you find Phoca extensions useful, please support the project
Post Reply