View Full Version : For Pekka: Non-global categories?
stevehof
31st of January 2003 (Fri), 09:13
I have a huge collection of images with many different types of subjects. I'd like to set up multiple exhibitions but the fact that categories are global makes it difficult to add more specific categories without making the category list very long. A long global category list might cause less than savvy visitors to get a lot of ‘no results’ returns. Do you have plans to make the categories specific to each exhibition instead of global any time in the future?
Thanks,
mandarinfish
31st of January 2003 (Fri), 21:12
Not Pekka, but if you don't have a problem with changing the php code, this is an easy thing to fix (I just did this for myself). I changed list.php to list only those categories which are used in the current exhibition. This is the new categories list portion of that file (I only changed the query parameters):
// GET CATOGORIES
$fetchgenres = mysql_query(
"
SELECT
DISTINCT
$q22,$q23,$q24
FROM
ee_category,
ee_photo_to_category,
ee_photo_to_exhibition
WHERE
ee_photo_to_exhibition.ee_exhibition_id = '$exhibition'
AND ee_photo_to_exhibition.ee_photo_id = ee_photo_to_category.ee_photo_id
AND ee_category.ee_category_id = ee_photo_to_category.ee_category_id
ORDER BY
$q22 ASC
"
);
if (!$fetchgenres) {
$queryname = "fetchgenres";
include($toroot . "db_error.php");
}
stevehof
1st of February 2003 (Sat), 00:17
THANK YOU!!!
No, I don't have a problem with hacking the php. Especially since you've provided the correct code, which I could not have done....
kd6lor
1st of February 2003 (Sat), 10:55
Mandarin fish. THANKS A MILLION. Yes I know I am shouting. Just updated my code. Took all of about 2 minutes including upload to internet.
Pekka, include this in future releases!!!!
Paul
Pekka
1st of February 2003 (Sat), 11:43
The reason I'm not including this particular fix to release is that it solves a problem by breaking other features. That is why I suggest that you do not apply that fix.
Example after above code change:
--------
You are in exhibition and choose category "sports". Now you change to another exhibition which does not have any photos in category "sports" so it will
a) display an error message (correct), and
b) the dropdown displays the first item in the category list belonging to the current exhibition (BUG)
Then you select a next exhibition and this time the category is what it was reseted to in previous screen, it can not try "sports" again as it lost reference to it.
--------
How it works now is that you choose "sports" and sports it stays - the 'not found' error message is clear and there is no problem loosing the search parameters while browsing exhibitions.
As you see changing logic in one area affects other features.
My suggestion as a solution to this problem:
---------
"Gray out" categories from the list that are not found in current exhibition. This would clearly tell to users what categories are available there now, and you can still choose and browse categories that are maybe missing in some exhibitions. The graying out must be done in CSS and it needs an extra query to get a list of nonvalid categories and doing a color desicion by comparing query results and printing the correct color code out into option tag.
When user selects or finds a gategory that has no images in current exhibition, EE will do an automatic search and present in the error page a list of exhibitions that contain those images, so you can pick one directly.
_This_ is something I'd like to code for release version.
---------
A long category list acts as an advertisement to browse somewhere which they originally did not plan to go. That is why I don't see it as a problem. Browsers will take care of making it scrollable when it is over certain size.
P.S. There is also a bug in EE 1.3RC which lets people see categories from password protected exhibitions. You can fix this by adding
AND ee_exhibition.ee_exhibition_pass = '$pass'
to the end of category query.
mandarinfish
1st of February 2003 (Sat), 12:42
Pekka, thanks for pointing out the problem. I only have two galleries and one is password protected, so I didn't test that transition.
I know that preferences in designing a user interface can be very subjective, but I think I'd prefer the categories not to be cluttered when looking at a particular exhibition. Part of the reason is that with my underwater marine creature photos, I have very specific categories (cephalopods, nudibranchs, etc.) which have absolutely no meaning to someone who might be browsing my land photos (which have more traditional categories similar to yours).
I see why you want to be able to have consistency in searching across exhibitions though. It's not an easy user interface decision. It might be useful to consider a slightly different interface for searching photos across exhibitions than within an exhibition. But I realize that this is entirely your choice.
For now, I will probably patch the bug by having the category default to all when a new exhibition is chosen, and then see what you come up with for the release version. Not to bug you about this but do you have any idea when you might have a release version?
thanks,
Linda
kd6lor
1st of February 2003 (Sat), 14:22
Bummer about the error when changing catagories. Will revert back to original file.
Thanks for the info.
Paul
Pekka
1st of February 2003 (Sat), 15:57
It is interesting to hear your views on how this should be in your opinion and by no means I'm not telling you NOT to do any changes to your EE's. There is only one thing that worries me generally is that there may in the end be dozens differently behaving EE's online, some worse, some better, and this will surely create confusion when you encounter new EE galleries. Also, logic problems and bugs there will surely be blamed on EE (my coding). That is why even a simpler solution NOW is what I prefer, until one day there will be new tested code to solve most wishes.
If there will be a solution which means each exhibition shows only categories it has, then all errors resulting in browsing should be fixed (i.e. menu shows in light gray "Sports - n/a in current exhibition", combined with error messaging with message like
---------
"Sorry, this exhibition did not contain any images in selected category. Please select another category or open any of the exhibitions below:
[link list to exhibitions containg photos in "sports" category]
---------
How does this sound?
mandarinfish
1st of February 2003 (Sat), 17:36
That sounds like an acceptable solution. Are you thinking of making a configurable option for whether or not all categories are shown in the lists? It certainly seems useful to me. Thanks for listening!
Linda
vBulletin® v3.6.12, Copyright ©2000-2012, Jelsoft Enterprises Ltd.