Wrong XML construction with ezxml

Author Message

Pierre Tissot

Friday 07 April 2006 5:22:37 am

Hi,

I'm using rssffeed to get information about a news channel, the language is in french but the character apostrophe is not well displayed. (this character is not weel display in this message so I will use the keyword apostrophe, and believe me that in the place should be a apostrophe :-D )

In the original xml document we have this element:

 

<p><img width="67" height="96" alt="affiche_enfant_fr.jpg" src="http://www.cominmagazine.ch/wp-content/uploads/2006/04/affiche_enfant_fr.miniature.jpg" id="image152" /></p>
<p>SynthesisBank, le leader Suisse de la banque d[apostrophe]nvestissement en ligne, collabore depuis plusieurs mois avec l[apostrophe]agence details.ch, de la conception de plaquettes institutionnelles, d[apostrophe]annonces presse, cartes de voeux jusqu[apostrophe]à la réalisation de banners publicitaires et de widget pour Internet.<br />
<br />
</p>
 

once ezplublish loads this file you have the same element whit a diferent content (put ? instead of a [apostrophe]):

 

        // New xml parser.
        $xml = new eZXML();

        $dom =& $xml->domTree( $rssFileContent );
 

doing the toString method we can see that the content is diferent:

 

      <![CDATA[<p><img width="67" height="96" alt="affiche_enfant_fr.jpg" src="http://www.cominmagazine.ch/wp-content/uploads/2006/04/affiche_enfant_fr.miniature.jpg" id="image152" /></p>
<p>SynthesisBank, le leader Suisse de la banque d?investissement en ligne, collabore depuis plusieurs mois avec l?agence details.ch, de la conception de plaquettes institutionnelles, d?annonces presse, cartes de voeux jusqu?à la réalisation de banners publicitaires et de widget pour Internet.<br />
<br />
</p>]]>
 

I try also with

        // New xml parser.
        $xml = new eZXML();
        $params= array("ConvertSpecialChars" => false);
        $dom =& $xml->domTree( $rssFileContent,$params );
 

but no lucky. Is this a bug? or I miss an episode?

Best regards
PiR

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 19 2025 07:26:07
Script start
Timing: Jan 19 2025 07:26:07
Module start 'layout'
Timing: Jan 19 2025 07:26:07
Module start 'content'
Timing: Jan 19 2025 07:26:07
Module end 'content'
Timing: Jan 19 2025 07:26:07
Script end

Main resources:

Total runtime0.0159 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0054 589.1641152.6250
Module start 'layout' 0.00540.0026 741.789139.4609
Module start 'content' 0.00800.0057 781.250089.3516
Module end 'content' 0.01370.0021 870.601630.3047
Script end 0.0158  900.9063 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002515.8770140.0002
Check MTime0.00117.1037140.0001
Mysql Total
Database connection0.00095.748210.0009
Mysqli_queries0.002213.980430.0007
Looping result0.00000.075110.0000
Template Total0.001610.110.0016
Template load0.00095.552810.0009
Template processing0.00074.469310.0007
Override
Cache load0.00063.983910.0006
General
dbfile0.00031.917680.0000
String conversion0.00000.046640.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0003 secs