Namran Hussin Linux,Webdesign PHP Fatal error: Class ‘DOMDocument’ not found in bla..bla..

PHP Fatal error: Class ‘DOMDocument’ not found in bla..bla..

from the tail -f /var/log/httpd/error

[Tue Mar 10 16:01:30 2009] [error] [client 127.0.0.1] PHP Fatal error: Class 'DOMDocument' not found in /home/namran/src/....php on line 15, referer: http://...

dom-not-found2

the solution turn out to be

yum install php-xml

complete-php-xml

21 thoughts on “PHP Fatal error: Class ‘DOMDocument’ not found in bla..bla..”

  1. approximately within 48hours.. hahaha.. (very slow-pace mode) as the file exist since..

    Mon Mar 9 15:28:31 2009 UTC (32 hours, 49 minutes ago) by ..

    quite weird when most of the item are just disappeared..
    .. at first thought some config problem.. removing the whole project directory and re-checkout.. still the same..
    then only figured one by one.. lol..

  2. I’m still having this problem. If done the yum install php-xml, but I still get the error about missing DomDocument class. I have read some posts that talk about executing a enable lib-xml extension command, but when I do this command, I get a error that lib-xml and extension is not a builtin command. Any suggestions would be appreciated.

  3. Updating the php-xml (note: it had already been installed long before the problem cropped up) on my CentOS server did the trick.

    Thanks for the help.

  4. Just a note, if you’re on centos and you had to do a custom install of php 5.3, yum install php53-xml will do the trick

  5. I also had to add the line:
    extension=dom.so
    to my php.ini file and restart apache. I’m using Fedora 16.

Comments are closed.

Related Post