[TYPO3-dev] A ticking ticking timebomb with libxml update to 2.7.1?
Lee Perry
leeperry at slack.de
Tue Aug 18 16:38:10 CEST 2009
Steffen Kamper schrieb:
> no. In my case the data was correct before and problem occured after
> server change. So when you have data it's correct in DB? Otherwise you
> have to renew the data completely.
that's the problem - before 2.7.1 my TYPO3 installations were configured
with:
[BE][flexformForceCDATA] = 0
that means in the database all my used FCEs were saved in the field
"tx_templavoila_flex" of the table "tt_content" without any CDATA area,
that means it looks like:
<field index="field_text">
<value index="vDEF">Lorem ipsum dolor sit amet, consetetur sadipscing elitr
<link news/details/nonumy-eirmod-tempor-2009-04-01.html _top
link-external "Takimata sanctus est 2009">more</link>
At vero eos et accusam <link voluptua/rebum/magna-aliquyam.html _top
link "At vero eos et accusam Magna Aliquyam">Magna
Aliquyam</link></value>
</field>
You see the tags are via htmlspecialchars() inside the XML but without
any CDATA. And there are a lot of tt_content elements and a lot of
projects - and I think I'm not the only one with such a CDATAless content.
"You have to renew the data completely." that's why I'm in panic - I
have to look for a small MYSQL replace to add this CDATA inside the
value-nodes of all flexforms.
Do you know all the different value-nodes?
I've seen today 2 different value-nodes:
<value index="vDEF"></value>
and
<value index="_TRANSFORM_vDEF.vDEFbase"></value>
so I can replace it via MYSQL with something like this (untested):
UPDATE tt_content SET tx_templavoila_flex = REPLACE(tx_templavoila_flex,
'<value index="vDEF">', '<value index="vDEF"><![CDATA[') WHERE CType
LIKE 'templavoila_pi1';
UPDATE tt_content SET tx_templavoila_flex = REPLACE(tx_templavoila_flex,
'<value index="_TRANSFORM_vDEF.vDEFbase">', '<value
index="_TRANSFORM_vDEF.vDEFbase"><![CDATA[') WHERE CType LIKE
'templavoila_pi1';
UPDATE tt_content SET tx_templavoila_flex = REPLACE(tx_templavoila_flex,
'</value>', ']]></value>') WHERE CType LIKE 'templavoila_pi1';
I have to test it ...
hmmm ...
More information about the TYPO3-dev
mailing list