Howto: Same category structure, different regional areas

Author Message

D K

Saturday 18 July 2009 9:39:49 am

Hello everyone,

I'm new to EZP, preparing a portal with information concerning events in different cities.
I can use some help strategically. So thanks in advance.

Picture an organic event like a modern circus consinsting of a) live music, b) acting and c) acrobatics. Just a stupid example.

An article about this event is to be written. And it should be written only once, yet published for all cities concerned.

What I want to do in the backend is: Pick the cities, for which the article is to be published. Then pick those three categories, and do that only once, but have them set for all the cities in their respective tree!

Look at http://www.timeout.com/ [which is not my site, just similar in structure], and imagine my circus touring through 10 countries and 20 cities each.

You really would not want do pick all three categories times 20 times 10, would you? Me neither.

Are there respective solutions, hints, suggestions?

kracker (the)

Sunday 19 July 2009 6:35:39 am

Hello,

I think I understand your concern.

Would you accept a php shell script
which would update a content object
subtree (parameter, int, nodeid) and
assign the desired attribute values (parameters).

./extension/assignattribvals/bin/php/assignattribval.php -v nodeid=2 values=(array)

In general this seems a little confusing
of an idea but one that I think is still
simple enough to implement using
the eZ PHP API.

Cheers,
<i>//kracker</i>

Member since: 2001.07.13 || http://ezpedia.se7enx.com/

Heath

Sunday 19 July 2009 6:46:09 am

While a script may be most flexible it is not always the most convenient for content editors.

I recommend a workflow event which performs the update (assigned to content update trigger).

In this way to complement a separate optional php cli script and or cronjob.

I also recommend defining your attribute values as custom settings. Ie: One set of attribute value settings per 'unique' set.

You may wish to even look into storing the value sets (to be applied) as content objects (Idea)

Cheers,
Heath

Brookins Consulting | http://brookinsconsulting.com/
Certified | http://auth.ez.no/certification/verify/380350
Solutions | http://projects.ez.no/users/community/brookins_consulting
eZpedia community documentation project | http://ezpedia.org

D K

Tuesday 21 July 2009 6:01:59 am

Thanks so far. I've forwarded your hints to my technical freelancer. From the point of view of an editor I'd like to ask, if there could be a solution, that might be more work in coding, but less work in editing afterwards.

Would it be possible to have two sets of main categories apart, and then let a query compose the right subfrontpages of the two instead of actually storing the content as duplicates in all those categories?

What I mean, in all my naivity as an editor, is:

On one hand I'd set my root categories, which also make the top level navigation on the homepage, i.e. concerts, parties, theater, art exhibitions, sport. These actually store all the content.

On the other hand I'd have a second set of categories apart from the first: geographical regions, which make an upstream alternate navigation, maybe triggering session cookies when clicked on.

If a region is picked, the whole top level navigation from then on refers to www.page.com/region/category instead of the original www.page.com/category.

Within www.page.com/region you can find only category frontpages, no folders. No content stored, but teasers.

Those frontpages are composed of content teasers matching both criteria: category AND region.

Clicking a teaser leads the user to the original storage place of the content in it's root directory.

Editing an article I'd choose my categories and regions once. And that would be it.

Could that be done, or is it nonprogrammer-nonsense?

Cheers
DK

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.