You need to be logged in to post in the forum - Log In

An active JCE Pro Subscription is required to post in the forum - Buy a Subscription

Support is currently Online

Official support hours
Monday to Friday
09:00 - 17:00 Europe/London (BST)

#115596 Cannot add JCE media custom field values

Posted in ‘Editor’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Latest post by Ryan on Tuesday, 19 December 2023 16:13 GMT

SigridGR
Hi, I think my issue is related to this issue: https://www.joomlacontenteditor.net/support/forum/115552 I am on Joomla 3.10.12 (already preparing the update), but it is for a magazine and there is a new issue tomorrow. The problem: I have a user custom field of type JCEMedia: a portrait. Since the update to JCE 2.9.57 when I open a user, the JCEMedia field looks like a normal input field - not like a media field. If I add any text/char and save, then the media field is shown. Then I can add an image. Then I save the user. But in the frontend I have the same issue as in the linked issue from above. My html code looks like this:

<img src="https://www.joomlacontenteditor.net/{" media_src":"images\="" comprofiler\="" XXX_www.jpg","media_text":"protrait="" xxx"}"="" alt="Portrait XXX" title="XXX">
Best regards Sigrid

Attachments

semaphore
Hi, It seems we are many to get this issue. The developper may confirm the way the information for JCE custom field is store moved to a simple path like images/nameoftheimage.jpg to JSON {media_src="https://www.joomlacontenteditor.net/nameoftheimage.jpg" ....} ? I just have to make some modification an override. For getting your path you have to use something like this :

json_decode($fields['image-de-l-article']))->media_src
where $field[] is your custom field. In my case I had to test like this

is_array(json_decode($fields['image-de-l-article'], true)
because it will don't display the old article image that still have the "simple path".

Ryan
I'm adding a "Legacy Support" parameter to the Media Field plugin to remove the additional Description field and revert to saving a single string value.

A beta will be available later today.

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

adi77
I have the same problem. I use the Custom JCE File Browser (Media) field in Yootheme for e.g. PDF downloads.
The file path is changed as soon as I fill in the "description field" e.g. from /image/documet.pdf to /images/ This is changed as soon as the "description field" is filled in (example path): /%7B%22media_src%22:%22images//document.pdf%22,%22media_text%22:%22test%22,%22media_supported%22:[%22img%22,%22video%22,%22audio%22,%22iframe%22,%22a%22,%22object%22]%7D"

The "description field" could also be hidden so that it is not used by users.

regards
adi

Attachments

Ryan
Please try JCE Pro 2.9.58 Beta - https://www.joomlacontenteditor.net/downloads/editor/pro/development

Go to System -> Manage -> Plugins (Extensions -> Plugins in Joomla 3), search for Fields - Media JCE and click on it to edit the parameters.

Set Legacy Media Support to Yes and Save.

Open and re-save any of the media fields you were experiencing issues with.

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

SigridGR
Thank you very much!
It works for my user fields now :-)

Jheroen
It also works (again) for my fields also

ligi
same problem here...after a full day of searching why our custom file fields were no longer working. 🙁 ...thank god we found this post...it works!! Tnx for that...my question is, will there be a long term fix....(instead of legacy ??? )

Ryan
will there be a long term fix....(instead of legacy ??? )


No, because the change is not a bug, it is an intentional feature addition. If you wish to use the JCE Media Field value in a non-standard way, directly from the database instead of via the JCE Media Field Layout (or a layout override), then you will need to the use the legacy option in future.

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.