Wednesday, April 14, 2010

easy way to install php dom/xmlreader/xxmlwriter/xml module on linux

[root@dev ~]# yum install php-dom
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* addons: mirror.eshk.hk
* base: mirror.eshk.hk
* extras: mirror.eshk.hk
* rpmforge: fr2.rpmfind.net
* updates: mirror.eshk.hk
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-xml.i386 0:5.1.6-24.el5_4.5 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

=============================================================================================================================================================
Package Arch Version Repository Size
=============================================================================================================================================================
Installing:
php-xml i386 5.1.6-24.el5_4.5 updates 96 k

Transaction Summary
=============================================================================================================================================================
Install 1 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 96 k
Is this ok [y/N]: y
Downloading Packages:
php-xml-5.1.6-24.el5_4.5.i386.rpm | 96 kB 00:18
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : php-xml 1/1

Installed:
php-xml.i386 0:5.1.6-24.el5_4.5

Complete!


Enable mudules (/usr/lib/php/modules/) in php.ini

echo "extension=dom.so" >> /etc/php.ini
echo "extension=xmlreader.so" >> /etc/php.ini
echo "extension=xmlwriter.so" >> /etc/php.ini
echo "extension=xsl.so" >> /etc/php.ini

#Reload apache
[root@dev ~]# /etc/init.d/httpd reload

1 comment:

Followers