Search
Other Articles Anywhere questions
Forum

Adding custom value to custom field

Juan Carlos Melean's Avatar Juan Carlos Melean
Hello,
since last upgrade, I cant add [url] value to my custom field,
I used to work with the following structure:

[my-custom-field layout="my-custom-layout" my_custom_extra_value="[url]"]

then, on my layout I used to echo $field->my_custom_extra_value to get the "URL" of the article,
now I'm just getting the string "[url]" instead of the url of the article.

could you please give me some ideas?

thanks,

Joomla! v4.3.4
Articles Anywhere v15.0.2PRO-dev2757337
Peter van Westen's Avatar Peter van Westen ADMIN
Please try the latest development version from:
regularlabs.com/development-releases
Please post a rating at the Joomla! Extensions Directory
Juan Carlos Melean's Avatar Juan Carlos Melean
Hello,
I'm sorry, but still having the same issue.
This is my workflow:
I have a custom module with following content:

{articles category="catepdy_name" date-custom-field-1=">date('today')" ordering="date-custom-field-1 ASC" fixhtml="false"}
[custom-filed layout="custom-filed-layout" my_value="[url]"]
{/articles}

my cusom-field-layout has:

....
if (!array_key_exists('field', $displayData)) {
return;
}
$field = $displayData;
$value = $field->value;
if ($value == '' || (string) $value == "NULL") {
$article_url = $field->my_value;
?>
<a class=".." href="<?php echo $article_url; ?>" target="_top"><?php echo strtoupper(Text::_('JGLOBAL_LEARN_MORE')); ?></a>
<?php
} else {
?>
....


the displayed link is: domain.local/ [url]

best regards.
Peter van Westen's Avatar Peter van Westen ADMIN
Can you give me (super) admin and (s)ftp 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.
Please post a rating at the Joomla! Extensions Directory
Juan Carlos Melean's Avatar Juan Carlos Melean
Hi, please find connection informations in confidential

Confidential information:
(hidden)


Thanks
Chris Mortensen's Avatar Chris Mortensen
[custom-filed layout="custom-filed-layout" my_value="[url]"]

In this line you have spelled 'custom-field' wrong in both instances.
Juan Carlos Melean's Avatar Juan Carlos Melean
in the description i'm using 'custom-field' as a reference, not the real name of the field.
did you verify the file on my server?
best regards,
Peter van Westen's Avatar Peter van Westen ADMIN
Please try the latest development version from:
regularlabs.com/development-releases
Please post a rating at the Joomla! Extensions Directory
Juan Carlos Melean's Avatar Juan Carlos Melean
It works, thank you very much!
Jc
Peter van Westen's Avatar Peter van Westen ADMIN
Ok, great 🙂
The fix will be included in the next release.
Please post a rating at the Joomla! Extensions Directory
You can only post on the extension support forum if you have an active subscription and you log in

Buy a Pro subscription