Search
Other Articles Anywhere questions
Forum

Articles Field Double Values

Alex R's Avatar Alex R
Hello Peter,

I am using Articles Field to link some articles. I want to display the intro text from the related articles on each article. However for some reason it is outputting everything twice. I tried the code listed here docs4.regularlabs.com/articlesfield/goin...rther/more-data-tags , but that did not work. With the below code I was able to pull the intro text from the related articles, but again everything gets pulled twice, meaning that the intro text for each related article shows up twice:
{articles individuals="current" articles="!current"}[introtext]{/articles}

Thank you for your help!
Andrea Malalana's Avatar Andrea Malalana ADMIN
Are you putting this code in the Custom HTML Layout of Articles Field?

If so, the code should simply be this, as described in the documentation:
{article [id]}[introtext]{/article}

That's all.

The filters are controlled by the Articles Field settings.
Alex R's Avatar Alex R
Hello Andrea,

I didn't try to put it in the Custom HTML Layout of Articles Field, but I did now and it works!

Thank you,
Alex
Alex R's Avatar Alex R
Hi,

This suddenly stopped working. I believe after and Articles Anywhere upgrade. See below my the config.

Confidential information:
(hidden)


Thanks
Peter van Westen's Avatar Peter van Westen ADMIN
Please try the latest development version from:
regularlabs.com/development-releases

Also, you should use:
{article id="[id]"}
Please post a rating at the Joomla! Extensions Directory
Alex R's Avatar Alex R
Thanks Peter! This helped me discover that the issue is not with articles anywhere but with the template I am using. So for now I need to use a module to get it to work with my template, however I am not sure about the code. I am using:
{article ignore-state="true" individuals="current"}[introtext]{/article}
which of course shows the introtext of the current article instead of the related articles. Can you tell me the code to display the related articles and not the current article.
Andrea Malalana's Avatar Andrea Malalana ADMIN
As described above, it should be:
{article id="[id]"}[introtext]{/article}
Alex R's Avatar Alex R
{article id="[id]"}[introtext]{/article}

Does not work and comes back empty.
{article ignore-state="true" individuals="current"}[introtext]{/article}

Does work, but obviously the current article instead of the related articles.
Andrea Malalana's Avatar Andrea Malalana ADMIN
Can you give me (super) admin access so I can take a look?

And tell me on what url I can see/reproduce the issue.

You can use the 'Confidential information' button in the forum editor to hide sensitive information.
Alex R's Avatar Alex R
Sure, can you send me your IP address so I can whitelist it.
Alex R's Avatar Alex R
Here is the info, i'll wait for the IP.

Confidential information:
(hidden)
Peter van Westen's Avatar Peter van Westen ADMIN
Use {articles …} instead of {article …}.
Please post a rating at the Joomla! Extensions Directory
Alex R's Avatar Alex R
I tried that as well and I am currently using it.
{articles ignore-state="true" individuals="current"}[introtext]{/articles}
Andrea Malalana's Avatar Andrea Malalana ADMIN
Confidential information:
(hidden)
Alex R's Avatar Alex R
I added the IP, you should have access now.
Andrea Malalana's Avatar Andrea Malalana ADMIN
Found the issue.
The syntax should have been this:
{articles individuals="this:id"}[introtext]{/articles}

This will show the articles where the field 'individuals' has a value of the ID of the current article, thus the articles that point to the current article via the 'individuals' field.

I've now updated it on your site and it should work as intended.
Alex R's Avatar Alex R
Thanks so much Andrea!
Andrea Malalana's Avatar Andrea Malalana ADMIN
You're welcome 🙂
You can only post on the extension support forum if you have an active subscription and you log in

Buy a Pro subscription