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

9
votes
4answers
32k views

How to --enable-dom without recompiling PHP?

From the output of phpinfo(), --disable-dom are included the configure command. How do I change it to --enable-dom without recompiling PHP? Edit: I'm using Fedora 10. The PHP i'm using is the one ...
4
votes
3answers
6k views

How to use FastCGI globally and Basic Auth in sublocations in nginx?

I recently deployed my first nginx setup and everything works really nice, except the location parsing is driving me nuts. I have a simple php fastcgi setup like this: location ~ \.php { if (!-e ...
3
votes
5answers
589 views

Good starting resources for system administration

I'm a PHP web developer and I'd like to start learning more about system administration and was wondering if anyone had any good resources/starting points to look at. I have an old computer I can ...
2
votes
1answer
399 views

Why HTTP sniffers aren't able to capture PHP generated HTTP traffic?

I can't get why HTTP Analyzer (I prefer this one because it is capable of decoding SSL encoded data transfered through HTTPS) isn't able to capture PHP generated HTTP traffic. It capture HTTP traffic ...
2
votes
4answers
6k views

Recommended method to upgrade PHP 5.1.6 to 5.2.x on CentOS 5.4

It's been awhile since this type of question was asked here. Perhaps the recommended solution has changed. I have a CentOS 5.4 mail server running RoundCube webmail. By default, RoundCube expects PHP ...
1
vote
0answers
80 views

Handling multiple server blocks in nginx configuration

I am working on setting up a proxy server for my application.The use case is I want a specific set of requests to be redirect to say abc.com and rest of the request to be redirected to xyz.com. Eg:If ...
1
vote
1answer
104 views

Dedicated Server emails ending up in Junk

I have a dedicated server that works fine. Recently I added a new domain with a new dedicated IP address. The emails from the webserver gets sent out from the primary IP address which is different ...
0
votes
1answer
99 views

What options do I have, to replace Apache web server? [closed]

I need a web server that runs php and does not create so many processes (today I checked the running processes list and there were like 90 of them called 'httpd', 300kb each), I only know these but I ...
0
votes
1answer
796 views

APC File Cache not working but user cache is fine [closed]

I have just got a VPS (with cPanel/WHM) to test what gains i could get in my application with using apc file cache AND user cache. So firstly I got the PHP 5.3 compiled in as a DSO (apache module). ...
0
votes
4answers
802 views

Which free antivirus can I use for a php application?

I need to analyze the files uploaded to my site. What options do I have? I'm in a dedicated, so I can install things on Linux. Is it normal for a site to analyze every file uploaded? Can this be done ...
0
votes
1answer
2k views

How can Django/WSGI and PHP share / on Apache?

I have a server running an established PHP site, as well as some Django apps. Currently, a VirtualHost set up for PHP listens on port 80, and requests to certain directories are proxied to a ...
0
votes
1answer
1k views

Configrue Exim Sendmail for relay

I have a VPS server at UltraHosting.com and requires that I use "Smart Relay" when sendning emails. However I cannot send mail using the php mail() function. Here is an article they have on Smart ...
0
votes
4answers
158 views

LAMP Staging Server with linux users

I need to have a mirror server of my production server so that I can test everything on that server first before implementing on production. To mirror production server I need to copy current PHP ...
7
votes
3answers
2k views

linux: one apache two php versions. possible?

it seems that some of my php applications require php 5.2 and some require php 5.3. is there a way to configure apache (v2.2.14) that one virtualhost will work with one php library and a different ...
4
votes
2answers
171 views

Recompiled PHP, now Apache not parsing PHP files

I recompiled PHP earlier today, now when you access PHP pages in a browser, Apache displays its source code instead of parsing it. Do I need to reset some configuration or recompile Apache? This is ...
3
votes
3answers
6k views

Apache executes HTML, but not PHP; PHP CLI works

I am running php 5.3.3 on rhel 6.2 with Apache 2.2.15 and am failing to get PHP code interpreted by Apache. There are no errors (in the system log, httpd/error_log, or php_errors.log) - I have ...
3
votes
2answers
564 views

install php on linux from 1and1 VPS

I am experienced in PHP, but I have never installed it. We have just upgraded onto a VPS from 1and1 and now we need to upgrade php ourselves apparently. We want to go from 5.1.4 to the latest, but ...
3
votes
5answers
2k views

Apache on Windows in production environment? Why not?

"Everyone" know that Apache is for Linux/Unix and on Windows IIS is the way to go. However, I'm not a pro at Linux and it would be an enormous relief for me to use just the same setup in the ...
3
votes
2answers
6k views

How to downgrade a certain ubuntu 10.04 package (php) back to karmic

I've updated from 9.10 to 10.04 but unfortunately the PHP provided with 10.04 is not yet supported by zend optimizer. As far as I understand I need to somehow replace the PHP 5.3 package provided ...
3
votes
5answers
776 views

Difference of running scripts manually or with a cronjob

I have a PHP script that I want to run every 10 minutes, going through database records and creating/editing movies through MEncoder. I've set up cron job to accomplish this, but it doesn't work very ...
2
votes
2answers
906 views

Getting rid of “Welcome to nginx!”

I've just setup nginx on my Ubuntu staging machince. Entering http://192.168.1.1./index.php works like a charm and loads the index.php file i've put in the /var/www/public_html folder. ...
2
votes
2answers
1k views

Failed installing APC?

I am trying to install APC on a gentoo with php 5.2 Here teh full command i Lanched: mkdir /home/APC-php cd /home/APC-php wget http://pecl.php.net/get/APC tar -xzvf APC cd APC-3.1.9 ...
2
votes
9answers
5k views

CronTab: Not running my PHP scripts?

final edit: i have moved this to http://serverfault.com/questions/168662/406-error-with-get-cron-job EDIT 4: i am getting a 406 error page with this cron! here is the crontab (copied from cPanel): ...
2
votes
5answers
4k views

How to prevent mail from our website going into spam mail of users?

I work for an educational services company based in India. We've around one million students enrolled as users. We're frequently facing the problem of our bulk mailers regarding upcoming exams, new ...
2
votes
3answers
3k views

Millions of files in php's tmp error - how to delete?

I've got a tmp-folder with 14 million php session files in my home directory. At least that's what I think it is, it's not like I could ls it or anything. I've tried using find with the -exec rm {} ...
1
vote
2answers
392 views

Installing php-fpm over php version missmatched

I have PHP installed by yum from the base @updates repository on Centos 6.3: php x86_64 5.3.3-14.el6_3 @updates 3.5 M I would like to install php-fpm version 5.3 because our web software works ...
1
vote
1answer
154 views

only django work in presence of mod_wsgi , PHP not working

I am using PHP with apache2 and MySQL on a rackspace server, it is unmanaged cluoud hosting. I am hosting multiple sites using virtual host. Now i want to use Django on it. A site needs django so I ...
1
vote
3answers
4k views

Safely update php 5.3.3 to >=5.3.4 on centos 6

Would the following works fine without any issues? I have apc cache installed, the other packages the usual php configuration. yum update php would that be enough? it is an active server, so want ...
1
vote
2answers
292 views

heavy load on mysql

i have dedicated server with very good configuation like 16 gb ram etc but i am facing heavy load from mysql i am running a music wesbite however only one database is running and 5-10 pages are only ...
1
vote
1answer
1k views

Downgrade PHP to 5.3 on Fedora 17

I'm trying to downgrade PHP to 5.3 on Fedora 17. Using yum downgrade I can only get as low as 5.4.1 (instead of 5.4.3). How can I install 5.3 using yum? I'm following the details at ...
1
vote
1answer
243 views

MongoDB not replicating properly

I am using mongoDB for my application hosted on 3 amazon instances. I have a got a Primary Node with highest priority (100) and 2 Secondaries with priority 99 and 98. A few days ago I started getting ...
1
vote
2answers
197 views

php.ini seems to be completely ignored

I'm working on a Dreamhost VPS, so I don't know if that has anything to do with this: The include_path entry in the php.ini file seems to be completely ignored. There are several php.ini files ...
1
vote
2answers
154 views

Apache security

I've been reading up on server/apache security and I've run into a contradiction. I read that you shouldn't serve any files that aren't inside Apache's scope, but I've been told that you should keep ...
1
vote
2answers
2k views

Apache, virtual hosts, and default sender for sendmail

So here's my issue...I have two sites hosted on one machine using apache's virtual hosts. I want to send emails from the two different sites (domain.com and domain2.com) using the appropriate email ...
1
vote
1answer
424 views

Intermittent error 404 during higher loads. (nginx/php/apc/mysql)

I have a 4 cpu core VPS with 4GB ram. It is running Ubuntu 10.04 with nginx/0.7.65, PHP 5.3.2, and MySQL. I use php5-fpm for the communication to nginx. I also have php5-apc complimenting with php ...
1
vote
1answer
3k views

Loading JSON in PHP53: ZVAL_DELREF in Unknown on line 0

I'm trying to loading JSON into the new-installed PHP5.3.1 on a CentOS server. Previously there was a PHP5.1 or near and due to the latest version of WordPress I had to upgrade the PHP. I tried to ...
1
vote
1answer
50 views

Using PHP configured for Apache with IIS

Here's my problem, I recently had to use IIS7 for one of my clients but he also wants PHP which is currently installed for my Apache setup on there. I can't find any ISAPI files in there, so I don't ...
1
vote
1answer
398 views

Make post title as a slug in url by mod rewrite

I have previously posted a question but I am not satisfied with the answers. I have a url, for example http://example.com/details.php?a=100&b=101&slug=power-programming-in-php I want to ...
1
vote
1answer
67 views

Certain web page cannot be retrieved

I have a simple web site in php served over apache running on ARM Linux. It normally works fine. But sometimes, certain pages cannot be retrieved at all. I have 5-6 pages. All the other pages would ...
1
vote
2answers
407 views

php returns junk characters at end of everything

php appears to be adding junk characters to the end of everything it returns on a friend's site. I'm not an admin on the server but I'd like to give an informed complaint to get this fixed. The site ...
1
vote
3answers
306 views

Can Apache 2 be configured to start sending gzipped data early?

We have Apache set up to gzip compress html pages before they are sent to the client browser. However, some of our pages are slowish to generate and it seems that Apache is holding on until it has ...
1
vote
2answers
1k views

How can I prevent users from seeing my PHP source code?

I tried to access my website recently and I saw something disturbing -- users could download the index.php file and see its contents, the PHP code! How is this possible, for Apache to serve up PHP ...
1
vote
5answers
1k views

User Specific Php.ini When php is ran as a module?

I have a php setting that can only be changed in the ini file. I can't change this setting in the global php.ini due to conflicts, so I'll need to have this user specific. Can this be done if php is ...
0
votes
1answer
228 views

Binding MySQL to run from the public or private LAN IP address - which one is faster

So we have 2 servers all running at the same web host. We have bind MySQL to listen on the public ip-address of the database server and the web server connects to it from the public ip. Both servers ...
0
votes
3answers
1k views

500 error after dragging joomla website out of subdirectory

I recently dragged a website I built with joomla out of a subdirectory and now the whole website just shows a 500 internal error, can't even log into the backend. I've already tried changing the log ...
0
votes
1answer
398 views

Install meteor server in debian (lenny)

I wonder how can I install this in a lenny machine. Well, this site has instructions on how to do this, but in step 3 I can't do cd /usr/local/meteor because this folder doesn't exist! How I can ...
0
votes
1answer
321 views

Apache / PHP server delaying for a minute before responding

Am having the strangest issue with an apache/PHP instance (PHP 5.2 in this case), where it will take over a minute to respond to a request. The PHP profiling is saying it's taking less than a second ...
0
votes
1answer
804 views

/var/www/ downloads php files instead of viewing them in browser [duplicate]

Possible Duplicate: My php homepage downloads index.php instead of being processed on Gandi.net hi im a newbie with servers so thats why i come here with my prob hoping you can help me. so ...
0
votes
2answers
140 views

php mail settings - proper values for my setup

We use a hosting company for our website but we have our mail servers hosted by our isp with our website domain; @sample.net. SMTP mail.isp.com On the website we have a contact form which emails ...
0
votes
1answer
693 views

No log handling enabled - turning on stderr logging Cannot find

I'm trying to setup a Cron Job that runs a .php file that will automate client email correspondance. I've created the .php file and the Cron Job through cPanel. Everything works fine in that I'm ...