Primary Category 1.0 Now Available! 
Posted: 12 March 2008 07:41 AM   [ Ignore ]
Administrator
Avatar
RankRankRankRank
Total Posts:  2732
Joined  2006-10-18

The Primary Category extension allows you to assign a primary category to an entry in ExpressionEngine using AJAX drag and drop. When you view a front-end page and have a weblog entries loop you can pull the primary category variables like all native EE category variables. Using the exp:primary_category loop, you can pull the same variables, so you have more flexibility. Additonally, your regular categories list is organized is a neat and tidy, controlled manner.

The Primary Category extension solves the problem of needing to have a “primary” category for an entry when it’s assigned to many categories… or even just 2.
No longer do you need to fiddle with sloppy workarounds… just one extra click, and your done. The template variables are easy, clean, and flexible!

Software Details for Primary Category 1.0

Primary Category 1.0 Documentation

Updated: May 2, 2008

Image Attachments
primary_category_1.gifprimary_category_2.gifprimary_category_3.gifprimary_category_4.gif
 Signature 
Profile
 
 
Posted: 12 March 2008 04:17 PM   [ Ignore ]   [ # 1 ]
Member
Avatar
RankRankRank
Total Posts:  66
Joined  2006-05-10

Hiya,

Sorry for posting in here like this but I think I must be tired or something as I can’t see what this does. Could you possibly let me know in words of no more than two-syllables? wink

Only kidding with the syllables bit just can’t quite get my head around what this is for?

Thanks.

Best wishes,

Mark

Profile
 
 
Posted: 12 March 2008 07:40 PM   [ Ignore ]   [ # 2 ]
Administrator
Avatar
RankRankRankRank
Total Posts:  2732
Joined  2006-10-18

Mark,

I hear yah! At first I had little clue as to what doors this thing opened…
I’ll start off by saying that it’s obviously not for all projects… only in certain instances…

First of all, you need to know that it flows seemlessly with the native EE Categories. By that, I mean that anything designated as a Primary Category is also a regular EE category. All the same EE category variables are available (except with the exception of the “primary_” prefix to each variable), and they work the same way.

Basically, what you would do is, create the entry, click the Category tab, check off all applicable categories, and then drag and drop over the category you want to be the “Primary” category for this entry.

I’m sure there’s many of different examples of how this would benefit you, but here’s a one.

1. If you use categories for sections, and sub categories for sub-sections, you at one point may need to specify or show details of the MAIN category. With regular EE categories, it will want to show all or nothing (categories), with the exception of some sloppy workarounds. Pulling the “Primary Category” variables does the trick without any hooplah....
I’ll further the example… say a new article belonged to “World News” but within that, it also belongs to the subcategory “Africa.” In a main feed on your homepage, you may want to display that it belongs to “World News”, instead of “World NewsAfrica”, much like EE would display it. So instead of using the {category_name} variable, you’d use {primary_category_name}.

I’ve attached some screenshots of how it looks in the CP

(Updated: see first post)

 Signature 
Profile
 
 
Posted: 13 March 2008 05:30 AM   [ Ignore ]   [ # 3 ]
Newbie
Avatar
Rank
Total Posts:  16
Joined  2007-07-03

Sweet. Can’t think of how I will use this yet but its good to know its available!

Profile
 
 
Posted: 13 March 2008 07:55 AM   [ Ignore ]   [ # 4 ]
Member
Avatar
RankRankRank
Total Posts:  66
Joined  2006-05-10

Hiya,

Thanks for the reply and the excellent screen-shots. Sounds very interesting and now I do understand wink

I must say though that I did do this on a site in the past once and I didn’t need any sloppy work-arounds fortunately. I got it to display just the one main level category on its own without any problems. Can’t remember what I did now but I know it wasn’t anything out of the ordinary though. I will see if I can remember which site out of the numerous sites I have made it was and find the code for you if I still have access rights to it as this would have been for a client so I may no longer be able to get in.

Does sound really good though and a nice bit of AJAX drag and drop going on there too which is nice to see! wink

Thanks again.

Best wishes,

Mark

Profile
 
 
Posted: 13 March 2008 08:10 AM   [ Ignore ]   [ # 5 ]
Administrator
Avatar
RankRankRankRank
Total Posts:  2732
Joined  2006-10-18

Yeah, there’s definately ways around it… some sloppy, some not… also depends on our definitions of “sloppy” haha LOL

There’s of course other instances where you might want to show only the Subcategory instead of the Parent… or you may have subcategories in subcategories… etc smile

 Signature 
Profile
 
 
Posted: 13 March 2008 11:12 PM   [ Ignore ]   [ # 6 ]
Member
RankRankRank
Total Posts:  99
Joined  2007-03-12

I really think you should consider creating some screencasts as part of your documentation. Obviously you have to use the product to create those screenshots in the first place so it’s a simple jump to show us it in action and how it affects things.

Sometimes words are not enough.

Profile
 
 
Posted: 14 March 2008 04:34 AM   [ Ignore ]   [ # 7 ]
Member
Avatar
RankRankRank
Total Posts:  66
Joined  2006-05-10

Or maybe I’m just not very clever wink

Thanks for putting up the screen-shots, perhaps they should be moved to the top post as it makes perfect sense now so thanks for that.

Best wishes,

Mark

Profile
 
 
Posted: 14 March 2008 08:05 AM   [ Ignore ]   [ # 8 ]
Administrator
Avatar
RankRankRankRank
Total Posts:  2732
Joined  2006-10-18
Stinhambo - 13 March 2008 11:12 PM

I really think you should consider creating some screencasts as part of your documentation. Obviously you have to use the product to create those screenshots in the first place so it’s a simple jump to show us it in action and how it affects things.

Sometimes words are not enough.

We are in the works of seriously overhauling our software section of the website in the near future.
Included will be revised documentation (some are just horrible… we know) LOL as well as screenshots, a lot more examples, tutorials, and perhaps some demos.

Thank you!

 Signature 
Profile
 
 
Posted: 14 March 2008 08:47 AM   [ Ignore ]   [ # 9 ]
Member
RankRankRank
Total Posts:  99
Joined  2007-03-12

No problems Pie Man. I sometimes find it hard to make the leap from a simple description to visualising a solution.

A quick demo showing how it affects the CP or some data sets me on the right path smile

Profile
 
 
Posted: 14 March 2008 09:31 AM   [ Ignore ]   [ # 10 ]
Member
Avatar
RankRankRank
Total Posts:  66
Joined  2006-05-10

Thanks for moving the images Pie Man. Looks like another great extension from the Solspace stable!! grin

Best wishes,

Mark

Profile