6

I have got in our company Joomla publication software to care about.

We are using Joomla to publish technical magazine articles. Mostly one article have 2-3 authors. In the past the admins solved this multiplicity with placing all author names in the beginning of article text. But this is not optimal for search article by authors, where the articles are showing only by the author which is assigned in the Article author-column.

I have looked for some module which allow us the multiple-author functionality, but without success.

And I’m not a Joomla expert to build my own extension. I got an idea how do this anyway:

Do you know some extension that can do some “Relations”?

It means that will create table where will be stored ID from Author with ID from Article? For example the Drupal CMS has Relation module to achieve this. From this database table I can do the operations we needed to show in frontend. My idea is described on this image.

We are using the K2 extension, but here in the “Extra fields” CCK we cannot add the extra field with Authors.

We are looking for solution with or withouth K2 extension.

I hope that some extension will be suitable to our problem, we don have capacity to hardcode this feature.

migrated from stackoverflow.com May 9 '14 at 14:38

This question came from our site for professional and enthusiast programmers.

  • If the main concern is front end search then you could just switch to using tags for authors. You could also make a contact record for each author and tag that. Then there are some display selected tags modules around that would let you display the list of articles with that author tag. There is one from last year's summer of code that is good for that but it's also very easy to make your own. – Elin May 7 '14 at 11:10
2

I have done the same thing for research journal last year in Joomla 2.5. I needed to use Community Builder for the author profiles. Look here for example: http://www.bwpat.de/ausgabe/25/schwarz-bretschneider

Then I used the extension fieldsattach to add a new field for the author IDs (and some more fields). In this field the author IDs in the correct order are manually written, i.e. 1345,2651

I copied the module article author and changed to code to get multiple authors. So now on each article page the authors are shown automatically in the right column.

And in the template overrides I could also get the author information from the CB user table, to show the author names and institutions just after the heading.

Edit: For showing the articles in the CB user profile (=author), I added a CB query field where I would look up the article id in the fieldsattach value table:

SELECT fa.articleid,fa.value,con.title FROM xxxx_fieldsattach_values AS fa LEFT JOIN (xxxx_content AS con) ON (con.id = fa.articleid) WHERE fa.fieldsid = '14' AND fa.value LIKE '%[user_id]%'

And in the row field I would add:

<li><a href="index.php?option=com_content&view=article&id=[column_articleid]">[column_title]</a></li>
  • Seagul, seems as very good idea. How are you solved the list of Articles by the author? Also modified the author module? – Fanger May 13 '14 at 8:01
  • added more details to my answer for showing the articles in the user profile. it is not the most performant solution, but it works so far. – seagul May 14 '14 at 8:57
  • looks doable now, we will try this next week, I'll refer after. – Fanger May 15 '14 at 10:42
  • Is it a Joomla 2.5? I could send you my mod_articles_authors. – seagul May 15 '14 at 11:41
  • Yes, that would be great! I have updated my contact profile here – Fanger May 20 '14 at 7:37
4

If the main concern is front end search then you could just switch to using tags for displaying the authors' names. Then you can add author information to the tag for each author and when you clicked the tag you'd get the author information plus the list of all items created by that author. You could also make a menu link for each author if you wanted to have some more control over the urls and layouts. As a practical matter that really depends on how many authors you're talking about and how much you want to automate.

You could also make a contact record for each author and tag that. Doing that would let you have more fields than just what you get in the tag description plus have the "contact me" form if you wanted.

Then there are some display selected tags modules around that would let you display the list of articles with that author tag. There is one from last year's summer of code that is good for that but it's also very easy to make your own module.

You could make a plugins to manage some parts of this also.

  • Yeah the Tag workarround sounds good, but we are using Tags for Article tagging. Do you know if its possible have two sets of tags for the article? – Fanger May 9 '14 at 7:58
  • So you'd essentially want to have two blocks of tags, one with the authors and one with the other tags? You could do this by using the nesting that is built in to tags, so make an author tag and then child tags for each name, then instead of using the core JLayout for the tags, make two and customize them so they call what you want. You'd want to get the data here and use the parent id to separate them out into the two groups. github.com/joomla/joomla-cms/blob/staging/libraries/cms/helper/… – Elin May 9 '14 at 8:37
  • Elin, I'm not sure If I still understand your tagging Idea. If we use tags, we want to have in the article 1) tags of authors 2) tags of article keywords. Ie: ad1) John Doe, Jonath Smith ad2) Military study, Vehicles, European conflict etc. Is this possible? – Fanger May 13 '14 at 7:59
  • Yes as I said, use the nesting feature of tags. Make a top level tag of author and only put the author tags under there. If you are doing more complex things like this you need to spend more time working out your structure and you can't just use the core JLayout, you need to create your own that matches the structure you want but it's not hard. The methods for getting the data are built into JHelperTags. It's not a workaround at all, tags are intended to be used to accomplish custom tasks like this; it was a use case that they were built to accomplish because users mentioned it. – Elin May 13 '14 at 9:31
  • Something like this github.com/elinw/mod_tags_child but then you'd probably also want to do an exclude variation. – Elin May 14 '14 at 10:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.