Bug: Commas break dependant fields
- James Riley
-
Topic Author
- Offline
- Platinum Member
-
Less
More
10 years 1 week ago #78784
by James Riley
James Riley .: EventBooking user since 2014 ::: JoomDonation user since 2016 :.
.: grfx & web design / IT / AV @ St. Therese Institute of Faith and Mission, Bruno, SK, Canada :.
Bug: Commas break dependant fields was created by James Riley
I was trying to set up a dependant field, where the parent item was a Radio field with the following values:
No
Yes, I will call you
Yes, please call me
In my dependant child field, every time I checked the No "depend on option", everything worked okay. However, if I checked off either Yes option and saved, the boxes would be empty.
Eventually, I realized that the "depend on options" are stored in the database as CSV (comma separated values), and that by selecting value that contained commas, I was breaking the CSV structure and EB couldn't match up the database entries with the values any more.
In the end, I changed my commas to colons instead, but I thought I would make mention of this behaviour as I am sure other users have tried and will try to use commas in their parent field option names, and have / will run into this same issue. Could the values written to the DB be somehow encoded to protect against correct vs incorrect CSV comma delimitation?
No
Yes, I will call you
Yes, please call me
In my dependant child field, every time I checked the No "depend on option", everything worked okay. However, if I checked off either Yes option and saved, the boxes would be empty.
Eventually, I realized that the "depend on options" are stored in the database as CSV (comma separated values), and that by selecting value that contained commas, I was breaking the CSV structure and EB couldn't match up the database entries with the values any more.
In the end, I changed my commas to colons instead, but I thought I would make mention of this behaviour as I am sure other users have tried and will try to use commas in their parent field option names, and have / will run into this same issue. Could the values written to the DB be somehow encoded to protect against correct vs incorrect CSV comma delimitation?
James Riley .: EventBooking user since 2014 ::: JoomDonation user since 2016 :.
.: grfx & web design / IT / AV @ St. Therese Institute of Faith and Mission, Bruno, SK, Canada :.
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
10 years 1 week ago #78790
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Bug: Commas break dependant fields
Yes
I can confirm this bug. It happens because my wrong decision storing data of custom fields. I should store these values in JSON instead of comma separated
Will find a way to address this (in backward compatible) in the version 2.5.0
Regards,
Tuan
I can confirm this bug. It happens because my wrong decision storing data of custom fields. I should store these values in JSON instead of comma separated
Will find a way to address this (in backward compatible) in the version 2.5.0
Regards,
Tuan
Please Log in or Create an account to join the conversation.
Moderators: Tuan Pham Ngoc
Support
Documentation
Information
Copyright © 2026 Joomla Extensions by Joomdonation. All Rights Reserved.
joomdonation.com is not affiliated with or endorsed by the Joomla! Project or Open Source Matters.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.