php - Transform large XML using XSLT -



php - Transform large XML using XSLT -

i trying transform big xml file (about 50mb) in php using next code:

// load xml source $xml = new domdocument; $xml->load($dir . 'xml/vapproducts.xml'); $xsl = new domdocument; $xsl->load($dir . 'all_products.xsl'); // configure transformer $proc = new xsltprocessor; $proc->importstylesheet($xsl); // attach xsl rules $resulttxt= $proc->transformtoxml($xml);

this works fine on local dev machine when upload hosting provider fails out of memory error.

is there way create transfor more efficient or incrementally rather loading whole xml file memory?

thanks,

john

php xml xslt large-files

Comments

Popular posts from this blog

xslt - DocBook 5 to PDF transform failing with error: "fo:flow" is missing child elements. Required content model: marker* -

mediawiki - How do I insert tables inside infoboxes on Wikia pages? -

Local Service User Logged into Windows -