• Hello Fabrik Community

    Fabrik is now in the hands of the development team that brought you Fabrik for Joomla 4. We have recently transitioned the Fabrik site over to a new server and are busy trying to clean it up. We have upgraded the site to Joomla 4 and are running the latest version of Fabrik 4. We have also upgraded the Xenforo forum software to the latest version. Many of the widgets you might have been used to on the forum are no longer operational, many abandoned by the developers. We hope to bring back some of the important ones as we have time.

    Exciting times to be sure.

    The Fabrik 4.0 Official release is now available. In addition, the Fabrik codebase is now available in a public repository. See the notices about these in the announcements section

    We wish to shout out a very big Thank You to all of you who have made donations. They have really helped. But we can always use more...wink..wink..

    Also a big Thank You to those of you who have been assisting others in the forum. This takes a very big burden off of us as we work on bugs, the website and the future of Fabrik.

Bug! Replace with icon

Status
Not open for further replies.

juuser

Well-Known Member
Hello,

I have noticed a problem when in element settings I choose "Replace with icons" and choose static icon, for example named "info" i get the following error in list header:

Warning: DOMDocument::loadXML(): Unescaped '<' not allowed in attributes values in Entity, line: 1 in E:\Apache24\htdocs\components\com_fabrik\models\element.php on line 684

Warning: DOMDocument::loadXML(): attributes construct error in Entity, line: 1 in E:\Apache24\htdocs\components\com_fabrik\models\element.php on line 684

Warning: DOMDocument::loadXML(): Couldn't find end of Start Tag span line 1 in Entity, line: 1 in E:\Apache24\htdocs\components\com_fabrik\models\element.php on line 684

Warning: DOMDocument::loadXML(): Extra content at the end of the document in Entity, line: 1 in E:\Apache24\htdocs\components\com_fabrik\models\element.php on line 684

These four rows are generated for every record in the list.

I have updated from Github a couple of days ago.

BR,
Martin
 
Hi Hugh,

Figured out the cause. These error lines only appear when I had "Replace with icon" selected and textarea element truncate on list was active. Disabled truncate and problem solved, at least for me. :cool:

BR,
Martin
 
"Retain HTML" was set to "no" when errors appeared. Now tried with "yes" and in this case no error messages appear. So it seems to be a combination of:

Replace with icons: ON
Truncate: List
Retain HTML: No

BR,
Martin
 
I'm still not entirely sure why that happens. The error you were getting means that an unescaped or unencoded '<' is getting into the data we're processing for the icon name. Even with "Retain HTML" set to No, we do ...

Code:
$text = htmlspecialchars(strip_tags($text), ENT_QUOTES);

... which should a) remove all html tags, and b) encode any < or > left in the text (that weren't part of a tag) into HTML entities like &lt; amd &gt;. So I just don't see how anything is slipping through that.

Oh well. As long as it's working now, I'm not going to worry too much about it.

-- hugh
 
BTW, what was your setting for "Show hover text", and was your data long enough to get truncated?

Bearing in mind the tooltip on the length setting (on words vs characters depending on HTML mode).

-- hugh
 
Hi,

"Show hover text" was "on", but data was not long enough to get truncated.

BR,
Martin
 
Status
Not open for further replies.
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top