PHP is a general-purpose scripting language that is especially suited for Web development. The online manual is an excellent resource for the language syntax and has an extensive list of the built-in and extension functions. Most extensions can be found in PECL.

learn more… | top users | synonyms

2
votes
1answer
916 views

How many fast-cgi processes to use with PHP-FPM and NginX

Does anyone know of a good source out there - or possibly can answer this in here - that can guide me as to how many Fast-cgi processes and Nginx processes I need to have running to serve a moderatly ...
2
votes
1answer
94 views

Session variables not persistent in PHP5/Apache2/Ubuntu12

I have a website that uses session variables (in PHP) to know if the visitor is entering the website or not. If he's new, then I redirect him to the detected language. But if he's not new, you let him ...
2
votes
1answer
733 views

nginx / php-fpm error logging

I'm trying to figure out where the PHP errors are going in my setup. I'm running nginx as the reverse proxy to PHP-FPM, but I'm not seeing the various E_NOTICE or E_WARNING messages my app is ...
2
votes
1answer
215 views

Zend 1 on Ubuntu with MSSQL not working

Does anyone know how to solve the following issue? If not, does anyone know how to setup Zend 1 on Linux to communicate with msSQL server? We get the following error in the nginx logs when trying to ...
2
votes
0answers
306 views

PHP 5.2, Apache 2.2, Windows 8, PHP not parsing

I have an apache httpd 2.2 installation on windows 8 (using the installer, installed to C:/Program Files (x86)/Apache Software Foundation/Apache2.2) and a php 5.2 installation (using the .zip, ...
2
votes
1answer
302 views

Can't install php5-apc from dotdeb source in Debian 6

I can't install php5-apc: ~# apt-get install php5-apc Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that ...
2
votes
0answers
317 views

PHP + ImageMagick Performance Issues

Good Day, I have two environments: OpenVZ VPS and Pentium 4 local dev machine. They have all packages installed the same way. ImageMagick is compiled from sources without OpenMP support. When I run ...
2
votes
0answers
194 views

php5-geoip performance issue

I installed the php5-geoip module on Ubuntu 10.04 via apt-get install php5-geoip. I've updated the geocities.dat library The production server performance decreased and load average is soaring. ...
2
votes
1answer
187 views

apache 2.2 with php 5.3 and miscrosoft sql 2008 crash

I am using Apache 2.2 with PHP 5.3 and Microsoft SQL Server 2008 on Windows Server 2008 64-bit. Every 3 to 5 hours, I get the error in the event viewer that Apache crashed for 20 seconds and then ...
2
votes
1answer
1k views

APC configuration on Ubuntu 10.4. Problem with apc.shm_size, apc.shm_segments and Apache

I installed apc on my ubuntu 10.4 vps today using the following lines. sudo apt-get install php-apc sudo /etc/init.d/apache2 restart While everything works fine. I encounter problems configuring ...
2
votes
1answer
46 views

pear creates old directory after php compilation

I have deleted /usr/local/php5.3 and compiled PHP 5.3.1 in directory /usr/local/php5.3.1. After installtion pear creates its pear.conf in /usr/local/php5.3/etc. I always thought that compiling in ...
1
vote
3answers
664 views

Problems upgrading from PHP 5.1.6 to 5.2.9

I have a web server running Fedora Core 5 (yes, I know it's very old) and it was running PHP 5.1.6 so I downloaded and compiled the source for 5.2.9 and restarted the server and phpinfo() still ...
1
vote
5answers
839 views

CentOS replacement for PHP development machine?

I'm just starting learning Linux. I'm using CentOS 6.3 and i really like it. However I need PHP 5.4, currently not available for CentOS. I've read that CentOS, for its very own nature, doesn't update ...
1
vote
3answers
2k views

PHP 5.4.6 or 5.3.16 for production?

On php.net, we can read : All users of PHP are encouraged to upgrade to PHP 5.4.6, or at least 5.3.16. Does it mean that it is better to use 5.4.6 than 5.3.16, even for production ? I have heard that ...
1
vote
2answers
243 views

PHP add virtual host dynamically

I'm developing a PHP web application that, among other things, needs to allow the user to add, edit and delete Apache virtual host entries. (I'm Including a web-writable config file in my ...
1
vote
1answer
2k views

I cannot install APC

I have php 5.3.6 and ubuntu. I want to install APC. When I do the $ pecl install apc, I eventually get an error: In file included from /tmp/pear/temp/APC/apc.c:44:0: ...
1
vote
1answer
13k views

How do I enable the IMAP functions in PHP?

I have a LAMP box running Ubuntu, Apache 2 and PHP5 with Slicehost. I'm a bit new to all this sysadmin stuff (I'm primarily a web developer). I need to use the IMAP functions in PHP, but they don't ...
1
vote
5answers
6k views

How to compile PHP 5.3 CGI?

php-cgi seems to have vanished in PHP 5.3.1. I've tried both the --enable-cgi and --disable-cli flags for ./configure, but it doesn't create a binary under the sapi/cgi subdirectory.
1
vote
5answers
3k views

How can I install PHP5 on Fedora Core 5?

I'm trying to install PHP5 from source on FC5 and everything is configures and compiles fine. When I try to run php however I receive the following errors. PHP Warning: PHP Startup: mysql: Unable to ...
1
vote
1answer
1k views

PHPMyAdmin is being attacked

I am running a Debian server with PHP5, Apache 2.2.16 and PHPMyAdmin (I don't know how to check the version number), Logcheck and some other programs. Today Logcheck begin to attach multiple lines ...
1
vote
2answers
409 views

Fedora 8 upgrade PHP > 5.2.4

One of my current company servers is using old Fedora 8 and web apps compatible with PHP 5.2.x. Currently the PHP version is 5.2.4. I would like to upgrade it minimum 5.2.5 so that Drupal-7 can be ...
1
vote
1answer
3k views

php5 fpm: how do you generate core dump from segfault?

Under load, my PHP5-fpm (on 32bit ubuntu 10.10) produces segfaults like the following: kernel: [4881937.884863] php5-fpm[2638]: segfault at 4204eb41 ip 0832d235 sp bfcea5e0 error 4 in ...
1
vote
1answer
460 views

what does the with-layout=gnu option do?

I am compiling PHP 5.3.6 and the compile configure command I am using as a reference uses the --with-layout=GNU option. I have done some research but I can't seem to find a detail answer. Can ...
1
vote
1answer
1k views

centos cron job running php file

I have a php file under php called test.php set to run every 5th minute of the hour. When ever I run the file manually (by going to the web browser and runnint the path) it works fine. But when the ...
1
vote
2answers
4k views

Error installing APC in apache2 VPS with php-5.5.1

When I install APC: pecl install apc I'm getting this error: Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. ...
1
vote
1answer
2k views

How do you completely purge Apache, MySQL, PHP, and phpMyAdmin on Ubuntu? [closed]

I really need to completely purge my web server on Ubuntu 12.04. I have tried sudo apt-get purge apache2 php5 libapache2-mod-php5 mysql-server libapache2-mod-auth-mysql php5-mysql phpmyadmin (which ...
1
vote
1answer
866 views

PHP5-FPM and 'ondemand'

I've set up a server with Nginx and PHP5-FPM, and things are running fine. However, as I add more and more sites to the server I see that the memory usage steadily increases, and I've come to the ...
1
vote
4answers
5k views

How to install php-devel under CentOS 6.3 x64?

I'm trying to install php-devel on my CentOS 6.3 VPS and get a failed dependencies test. From phpinfos(): SYSTEM Linux 2.6.32-279.5.2.el6.x86_64 #1 x86_64 NTS error: Failed dependencies: ...
1
vote
1answer
2k views

How can I protect files on my NGiNX server?

I am trying to protect files on my server (multiple types), with NGiNX and PHP. Basically I want people to have to sign in to the website if they want to access those static files like images. ...
1
vote
1answer
1k views

Disable DNS Caching PHP

I need to get the latest A records of a DNS in a script. The script is doing some monitoring operations. The Default TTL of DNS record is 5 minutes, but the monitoring script is running every minute. ...
1
vote
2answers
146 views

Visits from an ISP have 3x in two days, am I being DDoS?

My Google Analytics shows a very high increase of traffic from one ISP, being all unique visits coming from the same ISP and all of them using IE9/8/7/6. I'm getting 32% new (unique) visits, but now ...
1
vote
2answers
1k views

Ack! Upgrading Debian from Lenny to Squeeze has killed PHP!

Today I did a dist-upgrade from Lenny to Squeeze (I've done this before on many other servers without much trouble), and most everything seems to work except for PHP. Sites that use PHP just show the ...
1
vote
1answer
4k views

Debian Lenny apt-get install php5-cli Unmet dependencies help?

first time poster - long time reader and learner. Have been trying in vain for 2 weeks now to sort out a messed up PHP5.3 install on a Debian 5 (lenny) box. Each time I attempt to apt-get install ...
1
vote
4answers
7k views

“trying to connect via tcp://localhost:3306” problem with php mysql setup

I have installed the WAMp server on my windows XP machine. When I am trying to connect to DB it give the following error. Warning: mysql_connect() [function.mysql-connect]: [2002] No connection ...
1
vote
3answers
515 views

Can I log ALL Apache traffic?

I'm talking about all the traffic, including complete incoming and outgoing HTTP requests and responses. I'm using the latest Ubuntu, Apache2 and PHP, and need both the headers and the page data--the ...
1
vote
1answer
33 views

nginx 404 instead of 403 for empty directory

I have the following config for my nginx server: server { listen 80 default_server; server_name example.com www.example.com; root /var/www/example.com/web; index index.php ...
1
vote
2answers
620 views

PHP mysqlnd on Debian 6

I've installed php5-mysqlnd via: apt-get install php5-mysqlnd This is a brand new virgin Debian install with just apache2 and php5 via: apt-get install apache2 echo "deb ...
1
vote
3answers
438 views

Upgrade to the latest php by aptitude

I'm install php5 by aptitude, but php release the new version and recommend we upgrade. But I unwant to compile the new version by myself. How to upgrade the php to the newest version by aptitude?
1
vote
1answer
124 views

missing config files when compiling a php extension

I do the phpize.. When I reach the ./configure It tells me it can fins the php-config (configure: error: Cannot find php-config. Please use --with-php-config=PATH) I assume it means a file named ...
1
vote
1answer
901 views

Mounting an S3 bucket onto a AWS Ubuntu instance issues

i'm using s3fuse to mount an s3 bucket onto ubuntu, so that i can take advantage of the storage space. here are some environment info: System Info: Linux ip-xxx-xxx-xxx-xxx 2.6.38-8-virtual ...
1
vote
7answers
6k views

Apache is not interpreting .PHP files

I recently downloaded OpenSUSE OS version 11.4 from the site to use it as a server..In order to do that I downloaded the server edition that has Apache/2.2.17 and PHP5 downloaded by default.....Ok ...
1
vote
2answers
635 views

Able to configure/compile PHP --with-ldap, but LDAP is not listed in phpinfo()

I am trying to compile PHP with LDAP support using these lines: ./configure --prefix=/app/php --with-ldap=/usr sudo make sudo make install Everything appears to install fine without ...
1
vote
1answer
1k views

Ubuntu PHP5/Apache2 - Displaying 500 error instead of error message

The following script is not outputting error messages to the browser. Instead it results in an HTTP Error 500 response. <?php error_reporting(E_ALL); ini_set('display_errors', 'On'); phpinfo(); ...
1
vote
2answers
4k views

Where can I get php_mysql.dll for Windows?

I just installed Apache 2.2.17, PHP 5.2.14, and MySQL 5.1.51 on Windows XP. Apache is working and is loading PHP properly, but when I try to connect to MySQL, I get "Fatal error: Call to undefined ...
1
vote
1answer
139 views

PHP upgrading to 5.3.3 - what should I be aware of?

I have a VPS that's hosting half a dozen PHP-based sites. All is OK on php5.2.10 but I want to upgrade to 5.3.3. I have tested the functionality of the sites on my local dev machine running 5.3.1 and ...
1
vote
1answer
478 views

XCache loses performance gain after a day or so

I'm having some performance problems with XCache and PHP5 running on a Ubuntu 8.04 server. A few Zend Framework applications peak at about 12MB of memory. General response time before Apache 2 can ...
1
vote
3answers
2k views

Apache: How can I serve JavaScript via PHP?

I want to serve my JavaScript files via a PHP script. An example would be: If I were to request a JavaScript file called dir/my_file.js The server should redirect the request to a handler script ...
1
vote
2answers
2k views

Installing MySQL 5.1 & PHP 5.2 on RHEL5.3

I would quite like to be running the latest production releases of PHP and MySQL on my production RHEL5.3 server. PHP so that I can use Zend Framework 1.9 which only supports PHP 5.2.4 or later. ...
1
vote
2answers
105 views

Nginx and PHP working with <?php but not <?

I'm trying to configure nginx with shorthand open and close tags. Currently the following code works for example: <?php include('this.php'); ?> But this doesn't: <? include('this.php'); ...
1
vote
3answers
252 views

Best way to have both php 5.2 and php 5.3 at the same time in Ubuntu

I am using Ubuntu 12.04. I need (this is not an option) to have both php 5.2 and php 5.3 installed. I think I need to compile 5.2 from source and keep it in /usr/local or make checkinstall. Is there ...