PHP is a widely-used, general-purpose scripting language that is especially suited for web development.

learn more… | top users | synonyms

1
vote
1answer
405 views

Downgrade php version on debian

I have a big problem with my sites after I migrated to a new server. The only difference is the php version. On the old server I have 5.3.3-7+squeeze15 and on the new server there is ...
1
vote
1answer
4k views

How to install phpmyadmin 4.0 on Debian

Is there a way to install an up-to-date phpmyadin on Debian via apt-get? I only found a PPA for Ubuntu on the that you can install with sudo add-apt-repository ppa:nijel/phpmyadmin apt-get update; ...
1
vote
2answers
407 views

Arch Linux: I get 500 error when trying to open PHP file

I get the HTTP Error 500 (Internal Server Error) error with Chrome when trying to open a simple PHP file. I have installed Apache and PHP correctly as instructed in this article. Including the PHP ...
1
vote
2answers
3k views

Is there any command to enable/disable a php extension from command line?

Is there any command to enable/disable a php extension easily from command line? (php.ini)
1
vote
2answers
410 views

PHP package won't install correctly

Yesterday I did apt-get upgrade on my Debian/testing and broke a php5 package. I even tried to remove & purge with apt and dpkg clean apt cache. When installed again clean, it fails with ...
1
vote
2answers
8k views

Getting PHP to work with apache to run .php files through browser

I have VPS running Debian 5.0 (I think) and I would like to get it to run PHP files. I was told it needed to be configured with Apache. I tried entering the command apt-get install apache2 php5 ...
1
vote
1answer
45 views

What is Best Practice for running PHP in background?

When running the following on the command line it will be suspended until I issue the fg command: /usr/bin/php -r 'phpinfo();' & This is the case regardless if the PHP code is contained in a ...
1
vote
1answer
294 views

install php5-fpm on Debian Squeeze

I tried in many ways to install php5-fpm in om Debian squeeze, but couldn't. I was wondering if I have to upgrade php5.3.3 to higher version because it doesn't seem to work on lower than php5.4 I ...
1
vote
1answer
76 views

How to get “apt-get -y upgrade” within a PHP script to function as expected?

Yes, I'm aware of unattended-upgrade, but I don't like that package's limitations. I've got a PHP script that makes the following calls: ... system("/usr/bin/apt-get update"); ...
1
vote
1answer
206 views

How would I run Django and LAMP on different subdomains, but on the same Apache server?

I am currently working on a development project where I need to run four different PHP programs (both with MySQL backends) and one Django project. Current Plan: XenForo (forums.domain.com) [PHP ...
1
vote
2answers
432 views

shell script to find the combination of the array elements

I have a shell script in which I have defined an array. The array contains more than 2 elements. I need to find the combination of all the elements in my array. Suppose, if my array has the elements, ...
1
vote
2answers
47 views

Tracking from httpd instance to PHP script when PHP is a module

I'm trying to figure out exactly what's going on that kicks CPU usage in random httpd workers so high but I'm having a little hard of a time figuring out what PHP page is being requested so that I can ...
1
vote
2answers
522 views

PHP+FastCGI+nginx on Debian

I new with Debian. I want to use php on Debian. I do: apt-get install php5-cli php5-cgi spawn-fcgi Create file /usr/bin/php-fastcgi: #! /bin/sh PHP_FCGI_CHILDREN=3 PHP_FCGI_MAX_REQUESTS=1000 exec ...
1
vote
1answer
478 views

run a php script in centos and time and timeout

I want to run a php script in centos ( /usr/bin/php file.php ), and it takes long time to execute,and in the middle of executing , it stops running , and does not give me any errors. and I'm sure that ...
1
vote
1answer
4k views

PHP Upgrade Error (PHP 5.3.3 to PHP 5.4.19 on CentOS 6.4)

I'm using CentOS 6.4 and I was following this tutorial in order to upgrade PHP from v 5.3.3 to v 5.4.19 but I got the following error: Error: php54w-common conflicts with ...
1
vote
2answers
646 views

Compiling PHP and installing it under one directory

I have to compile a few versions of PHP in work but I need an apache service for each version running like we have on Windows. However the configure options seem to have different folders for ...
1
vote
1answer
211 views

Preventing script execution and file downloads in a directory?

I have a directory on my website where I'm storing files uploaded by users. I use a whitelist for uploaded file types and also save the files with hashed names, but from what I've read another good ...
1
vote
1answer
139 views

Bundle my scripts to make an installer in Unix?

We've got a PHP script running MongoDB in the background. I want to make it a bundle (Installer) for Unix. I will use it to install the following on any machines: Install Apache, PHP + MongoDB ...
1
vote
1answer
167 views

Delete key doesn't work properly in PHP interactive shell

In the interactive shell oh PHP Delete key is not working and produce ~ instead. Anyone know how to get this key to work? I am using Ubuntu 13.04 if this does matter.
1
vote
2answers
1k views

PHP exec command has the result 0 even if an error occurs

I have this PHP code: $execout=exec('ssh root@xxx.xxx.xxx.xx "sudo /etc/init.d/smokeping reload"',$output1,$result); if($result !=0){ echo"that can't reload"; } else{ echo "successfully ...
1
vote
1answer
264 views

Access Remote files through http path

I am using lamp on CentOS 6. Application code is written in CakePHP. Application files path is "/var/www/html/my_app". Another file server is mounted with an Application Server. Mounted path on ...
1
vote
2answers
1k views

Why does media wiki install stop?

I am building a new MediaWiki installation on a CentOS 6.4 system. Server version: Apache/2.2.15 (Unix) Server built: May 13 2013 22:11:16 PHP 5.3.3 (cli) (built: Feb 22 2013 02:51:11) Copyright ...
1
vote
2answers
4k views

What is the best place to put php files above server root directory?

I am running a web application and I want to move a directory containing my php files above the server root directory. Where would be the best place to put them? On my web server I rent from ...
1
vote
3answers
2k views

Curl not found (Glype)

I'm trying to install proxy software called Glype on my server. It continues to tell me that "Glype requires cURL/libcurl". I have the latest version of curl installed. Why might this be happening? ...
1
vote
2answers
1k views

How can I get crontab to use a different PHP installation location?

I have a MAMP setup which runs PHP 5.3.5 on my Mac OS X 10.5 computer. I am trying to install a crontab that executes a PHP script, which is located on my MAMP server. I can only get the crontab to ...
1
vote
1answer
1k views

Connect to a remote mysql server with bash php or perl

What is the best and lowest resource way to connect to a remote mysql server (server1.example.com) and execute queries like INSERT into SERVICES (user, id) ($user, $id) from server2.example.com? ...
1
vote
2answers
652 views

run script asynchronously / in a different process

I have a simple php script <?php for($i=0;$i<10;$i++){ sleep(1); echo $i; } Which I run from the command line php myfile.php & I would expect I can do other things in the command line, ...
1
vote
1answer
476 views

php - running shell command using shell_exec

I'm using an ajax call to execute "shell_exec" on the server (centos). The line that I'm executing is the following echo shell_exec("php -q /websockets/timedactions.php"); This is the server ...
1
vote
1answer
548 views

Can not execute some shell command from php

I want to execute phpcs commands from phpcode using shell_exec function. During execution it gives error /usr/bin/php: relocation error: /usr/bin/php: symbol X509_free, version OPENSSL_1.0.0 not ...
1
vote
1answer
151 views

cannot locate cacti files under /srv/www/cacti

I am installing cacti on SLES-11-SP2 following instructions on Open Suse Cacti guide but I cannot locate the cacti files under /srv/www/cacti after the installation. Do you have any idea where they ...
1
vote
1answer
166 views

Running cron jobs under php ver. 5.4

My hosting company switched me to php version 5.4. I run a Drupal site (D7.) They say: You'll want to make sure your crons use "/usr/php/54/usr/bin/php" instead, as otherwise it will use PHP 5.2. ...
1
vote
2answers
581 views

PHP exec expect script with SCP then SSH

I have a PHP page which runs the following expect script to upload a file to another server on my network: #!/usr/bin/expect -f set password [lindex $argv 0] spawn /usr/bin/scp /home/Dave/bin/test ...
1
vote
1answer
61 views

rpmbuild library register for 'requires'

Big Picture: I am building an in-house rpm for a customized php. I build an rpm which works, but generate library requirements that I can't seem to meet without using 'nodeps', which I want to avoid ...
1
vote
1answer
414 views

ERROR: could not find driver after changing from mysql to mariadb

mysql was working fine but I wanted to give mariadb a try on a new server I have going. However I am having an issue where all my php websites seem to have issues communicating with mariadb. Webmin ...
1
vote
1answer
97 views

xDebug compatible PHP editor/IDE for LXDE

Which PHP editor/IDE supports line by line debugging using xdebug on LXDE?
1
vote
1answer
7k views

Possible to install PHP 5.2.17 on a new CentOS 6.4 system?

I'm trying to set up CentOS 6.4 (Linux 2.6.32-358.11.1.el6.x86_64) with a specific version of PHP (5.2.17) as it is required by an app I'm trying to install. I've downloaded the PHP version and ...
1
vote
1answer
34 views

Searching multiple mysql tables for the same 2 fields in each table

I am trying to figure out how to search mysql tables for the same 2 fields. What I have is 2 tables in the same database. Below is what I have currently:- single search works ok SELECT * FROM ...
1
vote
2answers
772 views

Nginx + PHP + FTP - user permission issue

I have a wordpress copy installed on /home/username/public_html/site, and now the problem is : Nginx running PHP with "www-data" identity The site folder owner and group are "username", not ...
1
vote
1answer
334 views

nginx + php5-fpm + htdocs on USB

None of the configurations that I've looked up can help with setting up Nginx to serve PHP files on a mounted USB folder. I'm currently getting file not found when I try and access a PHP file on the ...
1
vote
2answers
768 views

How to meet required dependencies in order to install expect pecl extension on Mac OS X?

I am attempting to install the expect pecl extension. OS version = 10.7.3 PHP version 5.3.10 installed via macports expect version 5.45 installed via macports The command I am executing: ...
1
vote
3answers
5k views

Giving PHP permission to write to files and folders

UPDATED FOR FURTHER CLARITY: According to http://expressionengine.com/user_guide/installation/installation.html, it says: For most Unix hosts the following is typical, but you may check with your ...
1
vote
1answer
1k views

Why don't I see the XAMPP page on Linux Mint?

I am trying to install PHP MySQL on Mint 12. I downloaded and installed XAMPP. According to the tutorial, when I go to localhost in a browser I should see this: Instead, I see: It works! This is ...
1
vote
1answer
646 views

redhat oauth.so missing

I tried to put the oauth on my redhat server, but since I got this message : PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/modules/oauth.so' - /usr/lib/php/modules/oauth.so: ...
1
vote
1answer
1k views

How to remove Apache from CentOS while keeping php 5.3

I have a problem with removing Apache from my CentOS install. First of all I installed lighty (lighttpd) and then I tried to install php53 which httpd was included with it. I've configured lighty ...
1
vote
1answer
786 views

Backup Manager and Cron : CentOs and Ubuntu 11.10

I have two dedicated servers: one has CentOS, the other Ubuntu. I installed backup manager on both servers. But I have two different behaviors. On CentOS: The backup of my files is "every night". I ...
1
vote
3answers
3k views

Troubles installing php with MySQL support

So I wasn't sure if this question would go best here or on Overflow or Server Fault, but decided to try here first. I'm installing LAMP on a VPS, and am running into issues configuring and building ...
1
vote
2answers
376 views

process works without ampersand but doesn't work with ampersand

I wrote a small script to run as a daemon, everything seems to work when I run the command in unix: php script.php everything seems to work correctly, when I terminate that script and us the ...
1
vote
1answer
708 views

cURL on Linux not compiled, although installed

cURL is not compiled into PHP. I'm running: [root@vps ~]# cat /etc/issue CentOS release 5.7 (Final) Kernel \r on an \m Then I execute yum install curl and yum install php-curl. Then: [root@vps ...
1
vote
0answers
28 views

PHP script can't read CLI arguments when extra extensions are enabled in php.ini

I hope that I'm posting in the right StackExchange. I am facing a very strange problem with PHP CLI. I'm using Symfony Framework and I can't use Symfony's commands properly when I add extensions in ...
1
vote
1answer
22 views

load missing library from ~/ without root or symlinks on shared hosting?

So I have a library file that is used by a php module, both of which reside in my home dir on my shared hosted cpanel account. Problem is this library depends on libcrypto.so.6 and libssl.so.6 files ...