xml file

Author Message

Didier Kalulambi

Wednesday 17 November 2010 7:35:03 am

I want to read an xml file in my cron jobs. here is my php file:

"

<?php
//include_once( 'kernel/classes/datatypes/ezxmltext/handlers/input/ezsimplifiedxmlinput.php' );

function readXML( $fichier, $row )
{
$xml = simplexml_load_file( $fichier );

$tables = $xml[$row];

foreach( $xml->ROWDATA[0] as $table )
{


$dd[]=$table[0]['SIRET'];
$kkd[]=$table[0]['LIB_SOUSCLASSE'];
}

foreach($dd as $kk){

echo $kk; echo '<br />';
}
foreach($kkd as $kal){
echo $kal;echo '<br />';
}
}
$mod=date("d m Y ", filemtime("test1.xml"));
echo $mod; echo '<br />';
readXML( "test1.xml", "ROWDATA" );
?>

"

i need help to the "simplexml_load_file" to load my test1.xml thank you.

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 18 2025 10:42:42
Script start
Timing: Jan 18 2025 10:42:42
Module start 'layout'
Timing: Jan 18 2025 10:42:42
Module start 'content'
Timing: Jan 18 2025 10:42:42
Module end 'content'
Timing: Jan 18 2025 10:42:42
Script end

Main resources:

Total runtime0.0163 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.0059 588.9063152.6094
Module start 'layout' 0.00590.0033 741.515639.3984
Module start 'content' 0.00920.0050 780.914185.3047
Module end 'content' 0.01420.0020 866.218830.2891
Script end 0.0162  896.5078 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002615.7534140.0002
Check MTime0.00127.2820140.0001
Mysql Total
Database connection0.00085.014510.0008
Mysqli_queries0.002817.026530.0009
Looping result0.00000.105610.0000
Template Total0.001710.310.0017
Template load0.00095.523510.0009
Template processing0.00084.706510.0008
Override
Cache load0.00063.992310.0006
General
dbfile0.00031.720480.0000
String conversion0.00000.049940.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.0001 secs