Archive

Archive for the ‘PHP’ Category

How to install magickwand in linux

April 10th, 2013 No comments

How to install magickwand in linux

First go to the path where you want to download the tar file.

cd /usr/local/src/

Use the below link to download the magickwand tar file.

wget http://www.magickwand.org/download/php/MagickWandForPHP-1.0.9.tar.gz

Extract the file using the below command.

 tar -zxvf MagickWandForPHP-1.0.9.tar.gz

Go inside the extracted folder.

cd MagickWandForPHP-1.0.9

Run the below commands to configure and compile it with PHP

phpize

./configure

make

make install

 

 

Categories: PHP Tags:

How to install ffmpeg-php in linux

November 12th, 2012 No comments

How to install ffmpeg-php in linux

 

Login to server via SSH.

Go to the below path.

cd /usr/local/src

Download the tar file.

wget “http://downloads.sourceforge.net/project/ffmpeg-php/ffmpeg-php/0.6.0/ffmpeg-php-0.6.0.tbz2?use_mirror=garr”

Extract the tar file.

tar xjvf ffmpeg-php-0.6.0.tbz2

Go inside that folder

cd ffmpeg-php-0.6.0

run the below commands

phpize

./configure

make

make install

 

Categories: CPanel / WHM, PHP Tags:

How to Install EAccelerator, IonCube, Zend Optimizer, SourceGuardian, and SuHosin outside of EasyApache

June 30th, 2012 No comments

How to Install EAccelerator, IonCube, Zend Optimizer, SourceGuardian, and SuHosin outside of EasyApache

 

You can use /scripts/phpextensionmgr to install or uninstall these modules!

/scripts/phpextensionmgr list
Available Extensions:
EAccelerator
IonCubeLoader
Zendopt
SourceGuardian
PHPSuHosin

If you wanted to install Zend Optimizer use the below command.

/scripts/phpextensionmgr install Zendopt
Installing Zendopt
Determining PHP version
Installing Zend Optimizer binary
Activating Zend Optimizer in /usr/local/lib/php.ini
Zend Optimizer activated
Skipping install to /usr/local/php4, missing php.ini

 

Categories: CPanel / WHM, PHP Tags:

How to install php on linux server

May 7th, 2012 No comments

How/Steps to install PHP on Linux/CentOS server.

To install the latest version of PHP you can use the below commands.

yum list php*

It will show the available PHP packages.

yum install php*

It will install that latest php.

If you are getting –skip broken then follow the below command.

yum install php* –skip-broken

It will skip the broken dependencies and install the latest php.

 

How to install Stable PHP 5.2 on Linux/CentOS server.

First check which php packages are available.

yum list php*

It will show php5.1 and 5.3. To install 5.2 PHP you have to install php5.1 and then upgrade it. To install php5.1.x you have to select the package name and follow the below command.

yum install php-*

It will install php 5.1.x on the server.

Now upgrade php5.1.x to 5.2x

rpm –import http://dev.centos.org/centos/RPM-GPG-KEY-CentOS-testing

Go to the yum repo directory

cd /etc/yum.repos.d

Download the  CentOS-Testing repo

wget http://dev.centos.org/centos/5/CentOS-Testing.repo

Update to PHP5.2.x

yum –disablerepo=* –enablerepo=c5-testing update php

Install extra package

yum –disablerepo=* –enablerepo=c5-testing install php-xml

Restart Apache and make the Apache start on boot.

service httpd restart
chkconfig httpd on

Now check the PHP version:

php -v

It will show the below output

PHP 5.2.17 (cli) (built: Feb 21 2011 04:28:54)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies

Categories: PHP Tags: , ,

How to install imagick on linux

May 7th, 2012 No comments

How to install imagick on linux server

Login to server as root

cd /root/download

wget http://serverip/imagick-3.0.1.tgz

tar -xzvf imagick-3.0.1.tgz

cd imagick-3.0.1

phpize

./configure

If you are getting error message then run /scripts/installimagemagick

make

make intall

add the below line in php.ini (path of php.ini on server/usr/local/lib/php.ini)

search mysql.so enter the below line under that

extension=imagick.so

Restart Apache

In php -m imagick should be listed

 

Manual Installation:

Download ‘Imagick’ from ‘pecl.php.net’.

wget http://pecl.php.net/get/imagick-3.0.1.tgz

Extract.

tar -zxf imagick-3.0.1.tgz

Configure and Install.

cd imagick-3.0.1

phpize && ./configure

make

make install

 

How to install the imagemagic on Linux server

May 7th, 2012 No comments

How to install the imagemagic on Linux server

/scripts/installimagemagic

How to rectify if ImageMagic is installed on server :

Run below command

[email protected] [~]# identify -version

Version: ImageMagick 6.4.8 2010-06-27 Q16 OpenMP http://www.imagemagick.org

Copyright: Copyright (C) 1999-2009 ImageMagick Studio LLC

If the identify program executes and identifies itself as ImageMagick, you may not need to install ImageMagick from source unless you want to add support for additional image formats or upgrade to a newer version. You also have the option of installing a pre-compiled binary release. However, if you still want to install from source, choose a platform, Unix or Windows. Before installing from source, you may want to review recent changes to the ImageMagick distribution.

Command to check the ImageMagic Version

/usr/bin/convert

Version: ImageMagick 6.0.7

To check the Imamagic enable on the server or not

Open command prompt and type

]#which convert

It will return below output

/usr/bin/convert

Path for Imagemagick on server:

[email protected]# whereis ImageMagick

Below is the output :

ImageMagick: /usr/include/ImageMagick /usr/share/man/man1/ImageMagick.1

How to install memcache

December 28th, 2011 No comments

How to install memcache

Definition:

Memcache is a high-performance memory object caching system intended to speed up dynamic web applications by alleviating database load. Memcache is extremely fast. It uses libevent, which provides a mechanism to execute a callback function when a specific event occurs on a file descriptor, to scale to any number of open connections. On a modern Linux system memcached utilizes epoll, is completely non-blocking for network I/O, ensures memory never gets fragmented, and uses its own slab allocator and hash table to achieve 0(1) virtual memory allocation.

How it install memcache:

#curl -O http://monkey.org/~provos/libevent-1.4.9-stable.tar.gz

#tar -xzvf libevent-1.4.9-stable.tar.gz

#cd libevent*

#./configure

#make

#make install

Now let’s download the newest Memcached source

#curl -O http://www.danga.com/memcached/dist/memcached-1.3.0.tar.gz

#tar zxf memcached-1.3.0.tar.gz

#cd memcached-1.3.0

#./configure

#make

#make install

Then add /usr/local/lib to LD_LIBRARY_PATH in your .bash_profile

LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
export LD_LIBRARY_PATH

Add the below link in php.ini of the server

extension=memcache.so

Now restart Apache:

Service httpd restart

Once it sucussfully install you can create phpinfo() on your webserver should now confirm that memcache is installed.

 

Categories: Installation, PHP Tags:

How to install APC for php in linux server

December 20th, 2011 No comments

How to install APC for php in linux server

pecl install php
 

You can use the below steps to install it manually.

wget http://pecl.php.net/get/APC
tar -zxf APC-3.1.9.tgz
cd APC-3.1.9
whereis php-config
./configure –enable-apc –enable-apc-mmap –with-apxs–with-php-config=/usr/bin/php-config
make
make install
restart the apche
/etc/init.d/httpd restart
 
 
If you are getting below error message :
/root/tmp/pear/APC/apc.c:454: error: ‘apc_regex’ has no member named ‘preg’
then you have to intall php-devel on server.
you can check the php-devel packages using the below command.
yum list php-devel
Once it will show the packages then you can install it using the below command.
yum install php-devel

 

Categories: Installation, PHP Tags:

How to enable php.ini for all the folders under one account

December 14th, 2011 No comments

 How to enable php.ini for all the folders under one account

Copy the php.ini file in the public_html folder of the user using below command.cp /usr/local/apache/php.ini .

Then create .htaccess file and insert the below command:

SetEnv PHPRC /home/username/public_html

Note: In place of username you have to use the clients or your username.

 

Categories: PHP, Uncategorized Tags: