Search:
Main Menu
Login | RSS |

Quick PHP Code Tips and Examples

PHP Programming Tips, Tutorials and Source Code Examples for newbie

DOM-XML extension not working in PHP 5?

March 10th, 2007 by Jon Moffet

If you're porting your PHP4 scripts that uses DOM-XML for xml-parsing to PHP5, then you might have stumbled into this particular problem, PHP5 has no DOM-XML extension.

This is because PHP 5 has a new integrated DOM functions which replaces PHP4 dom-xml equivalent.

However you don't need to do a complete rewrite in order to make your DOM-XML PHP 4 scripts work with PHP 5. All you need to do is to include a fix from http://alexandre.alapetite.net website.

First, download domxml.phps, then include it in your php scripts

PHP:
  1. require('domxml.phps');
  2.  
  3. // the rest of your script that uses dom-xml goes here...

After that your PHP4 script is able to work normally in PHP5 environment :)

Tags: , , , , ,

Bookmark Post:These icons link to social bookmarking sites where readers can share and discover new web pages.
  • NewsVine
  • Reddit
  • Netvouz
  • Spurl
  • Furl
  • digg
  • YahooMyWeb
  • del.icio.us

Posted in Uncategorized |

Related Posts

Leave a Comment

Please note: Comment moderation is enabled and may delay your comment. There is no need to resubmit your comment.