PHP DOMDocument missing

后端 未结 3 1412
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-11 03:33

I am getting an odd error when running $dom = new DOMDocument(\"1.0\", \"utf-8\");: Warning: require_once(classes/DOMDocument.class.php) [function.require-once]: fai

相关标签:
3条回答
  • 2020-12-11 04:11

    Fixed with:

    sudo yum --enablerepo=webtatic install php-xml
    sudo /sbin/service httpd stop
    sudo /sbin/service httpd start
    
    0 讨论(0)
  • 2020-12-11 04:18

    First Install this rpm

    rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm

    Then install

    sudo yum --enablerepo=webtatic install php-xml

    This should 100% works.

    0 讨论(0)
  • 2020-12-11 04:30

    I had same issue, I have php71 REMI installed on Centos7.

    I checked this:

    yum install php-xml
    

    But It was installed and I got this message:

    Package php-xml-7.1.4-1.el7.remi.x86_64 already installed and latest version
    

    Then I tried this one:

    yum install php71-php-xml
    

    And It was missed, So I got

    Dependencies Resolved
    
    =====================================
     Package                    Arch                Version                        Repository         Size
    =====================================
    Installing:
     php71-php-xml              x86_64              7.1.4-1.el7.remi               remi              164 k
    
    Transaction Summary
    =====================================
    Install  1 Package
    

    I answered yes and It installed. Then restart the httpd2.4:

    service httpd restart
    

    Then the problem was fixed.

    0 讨论(0)
提交回复
热议问题