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

1
vote
0answers
29 views

Vagrant, Apache and FastCGI uses huge cpu

I cannot really grasp why it's so slow. Site loads really slow. And vboxheadless hits more than 100% cpu every request. I use 2048 memory and 1 cpu. Here is activity monitor and top: http://imgur....
1
vote
0answers
24 views

nginx prevent loss of POST parameters when rewriting uri

I would like to do some url rewriting on nginx with php-fpm. Namely, routing all requests to php scripts to a single script like: /index.php?fulluri=(originaluri) Many ways to approach the problem: ...
1
vote
0answers
76 views

have xmpp (ejabberd) server authenticate with existing user database (MySQL)

Let me start off by stating that I know very little about the XMPP protocol or real-time communication in general. I did however manage to set up an ejabberd server with TLS encryption. I have written ...
1
vote
0answers
51 views

Install Pecl PAM authentication Apache

I want to setup horde webmail 5.2.9 on my server (debian Jessie). When I go to localhost/horde/test.php I get: PAM Support (PECL extension): No The PAM PECL extension is required to allow PAM ...
1
vote
0answers
63 views

Apache user directory refuses connection when I enable PHP module on OS X 10.11

I'm trying to configure the user director /Users/username/Sites in Apache. If I comment out the PHP LoadModule it works fine, and somehow PHP7 is even loaded. Problem is that I need to use PHP5, but ...
1
vote
0answers
41 views

httpd processes cpu spike to 100%+ every xx seconds

My first post, unfortunately due to an issue on my dedicated (Linux Centos 6) server running some personal and one commercial website. Server version: Apache/2.4.18 (Unix) Server built: Mar 7 2016 ...
1
vote
0answers
141 views

Error with PECL command in PHP7

I've upgraded php to version 7 and now I have problems with pecl command. When I run sudo pecl install mongo I get long list of errors: Warning: Invalid argument supplied for foreach() in Command.php ...
1
vote
0answers
349 views

Using PHPMailer on Hostgator (timeout when try to login into SMTP server)

Solved: The problem was that to use the service through hostgator, for some reason the user must log in using main dsn name and not the SMTP domain name. I was using the simple PHP mail() function to ...
1
vote
0answers
89 views

installed new version of php, apache downloads php files instead of serving them in browser

I have been developing on Mac OS X Yosemite with apache2 and php5 for months. (Note my webdirectory is ~/Sites). Recently, was designing some PHP scripts, and wanted to run them from the command ...
1
vote
0answers
31 views

Reducing inodes usage on vServer

On my Linux vServer the inodes are limited (maximum is 250k). I found that an Yii2 (PHP, MySQL, composer) installation requires quite a lot of inodes. The number of inodes is roughly the number of ...
1
vote
0answers
29 views

Copy PHP website to virtual folder under IIS 8.5

I would like to make an existing PHP Website (Apache) run on a virtual folder under IIS 8.5. With the help of some nice online tools I translated the following .htaccess content: <IfModule ...
1
vote
0answers
32 views

configure exim4 on ubuntu with let's encrypt

I need to send mail for a website of mine using PHP mail(). I wanted to make sure this mail is sent encrypted. I already have exim4 sending mail via PHP, but want to make sure it's using a ...
1
vote
0answers
29 views

Handling errors with php on nginx reverse proxy, and mail response to admins

Is there a way to access the server response from php once Nginx detects an error, and mail the server response to the admins while at the same time show a custom error page to the visitor? Currently ...
1
vote
0answers
33 views

Warning: mysql_connect(): Host 'ip-X-X-X-X.ec2.internal' is blocked because of many connection errors

I'm using following system: $ cat /etc/redhat-release Red Hat Enterprise Linux Server release 7.1 (Maipo) $ uname -a Linux ip-X-X-X-X.ec2.internal 3.10.0-229.14.1.el7.x86_64 #1 SMP Tue Aug 25 11:21:...
1
vote
0answers
82 views

migrating htaccess from Apache to nginx

I'm trying to start using Homestead for my non-Laravel projects (legacy) and I managed to install box 0.3.3 successfully by cloning laravel/homestead 2.2.1 (with PHP 5.6.15). Now my problem is due to ...
1
vote
0answers
84 views

Getting 404 Not Found while PHP works in background - Nginx

I have noticed that I get 404 - Not Found when calling a .php file even if the script works in background. The php file downloads a long Json and populates a db until I close the window. I am using ...
1
vote
0answers
66 views

PHP page refuses to appear despite checking php-fpm, SELinux, and nginx

Problem I have a small web server that hosts a small PHP page that performs a very small function. I used to host this on another machine. I move the website to a new machine with a different ...
1
vote
0answers
136 views

Enable XSendFile on Apache on Mac OS X 10.10 - “Invalid command 'XSendFile'”

I have compiled and installed sendfile 0.12 on our mac web server. The module is enabled in the httpd.conf file, as below: LoadModule xsendfile_module libexec/apache2/mod_xsendfile.so I've ...
1
vote
0answers
14 views

Apache2 mod-fcgi seperate users for two applications

I try to configure my apache like this: https://www.howtoforge.com/how-to-set-up-apache2-with-mod_fcgid-and-php5-on-ubuntu-8.10 The point is that I want to have an user for typo3 and one for ...
1
vote
0answers
42 views

Apache using all cpu and cause OOM killer

I have an Xen-VPS CentOS 6.5 64 Bit with 2GB memory and 4 GB Ram, I have application with php, in my application lot of pages need to image which generated by php_imagick extension, here is apache ...
1
vote
0answers
49 views

FastCGI and tmpfs

I read some articles about using tmpfs for /tmp and PHP sessions directories for better performance, and it sounds interesting. I'm using Centos 6 server with LAMP stack (+FastCGI) and in my fcgid....
1
vote
0answers
58 views

php-fpm error log is trucated

I'm setting up test environment where I have nginx and php-fpm on centos 7. I have successfully setup everything and I can run php code. This is my configuration: nginx version: nginx/1.9.9 ...
1
vote
0answers
24 views

sending back rewrote url without forcing a new request

The user of my application issue commands (create new post, delete comment etc.) via links with nonce parameter. As this is transported via GET the URL bar contains this technical detail. I want to ...
1
vote
0answers
108 views

CentOS PHP upgraded, now downloads all pages

I had to upgrade PHP to 5.6 to get access to a new function for locales and translation. I removed the old PHP and added the new PHP from the Remi repo as specified here. I restarted Apache and now ...
1
vote
0answers
91 views

PHP compiled with zlib, but doesn't appear in phpinfo()

I have a program that requires PHP to be configured --with-zlib, so I re-ran ./configure, make and sudo make install PHP 5.6.15 on my Ubuntu 14.04 server. However, the program still says that PHP wasn'...
1
vote
0answers
177 views

Hosting a php website in windows server 2008 with apache

I have an asp.net website hosted in IIS 7 in windows server 2008 which is running perfectly and is hosted on local server. I have only purchase the domain name without the hosting cuz the site is ...
1
vote
0answers
40 views

handle 2k image request a second with nginx

We have made an app that displays dynamic images. We are trying to handle a load of 2k image request a second with nginx. The size of the image is about 0.13 mb and we are using php with this code to ...
1
vote
0answers
117 views

Installing an intermediate cert on Debian 8 for curl/openssl connections.

I am trying to contact a url via php's stream_socket_client() command which is failing with no error code or msg. Does this use openssl, curl or something else? The site uses https and works fine from ...
1
vote
0answers
96 views

php-fpm pool processes taking 250MB each

My centos 6.7 server has only my php and mysql based low-traffic websites (total around 3000 page views per day for all websites) using nginx web server and virtualmin (no wordpress or external ...
1
vote
0answers
20 views

IIS server slows down with only a few tens of requests

I'm using IIS 7.5 with PHP and I'm having troubles with my application, it is VERY slow and it can take more than 30 seconds to respond sometimes. I believe this is due to some kind of queue of ...
1
vote
0answers
174 views

Symfony No Access to Cache - Red Hat 7

I'm running amazon EC2 VPC, normaly use Centos and I have no problem with it, but I have tried Red Hat Enterprise Linux Server release 7.1, and I have installed everything from scratch. I'm using ...
1
vote
0answers
478 views

nginx: An existing connection was forcibly closed by the remote host

I am running nginx on Windows Server 2008 R2 and it seems to be crashing, it also uses php-cgi with it and the php-cgi is part of the problem. After about 30 seconds of being on the page php-cgi ...
1
vote
0answers
120 views

Client denied by server configuration - IP listed is server's own IP

Something odd is happening on my server. The Apache log shows lots of requests from the server's own IP address. I do not suspect the server is compromised. I suspect some PHP code is malfunctioning ...
1
vote
0answers
173 views

elFinder with NFS: Unable to upload “image.jpg”

I have a NFS mount with permissions 770 on user:group "nfsbackup:nfsbackuo" with www-data as member of group nfsbackup. This is my server connector configuration in PHP, using CodeIgniter 2, working: ...
1
vote
0answers
112 views

IIS server: directory not writable via symbolic link compared to directory junction (for only the first user)

We have the following setup for a webserver: Windows Server 2008 R2 Standard, IIS 7.5.7600.16385, PHP 5.3.28, the HMVC framework we use is Kohana. Kohana needs a cache directory to be writable in D:\...
1
vote
0answers
153 views

Nginx can't speak with uwsgi (prematurely closed connection)

What I'm missing in my nginx/uwsgi/php-embed configuration? rpm -qa|grep php php-cli-5.4.16-36.el7_1.x86_64 php-xml-5.4.16-36.el7_1.x86_64 php-devel-5.4.16-36.el7_1.x86_64 php-common-5.4.16-36.el7_1....
1
vote
0answers
54 views

Use different client IPs with mod_rewrite and mod_remoteip

I have a reverse proxy that my site points to to help with DDoS protection. I have mod_rewrite set to use a specific header provided by the reverse proxy in order to pull the actual client IPs instead ...
1
vote
0answers
46 views

Changes done on EC2 instance took effect after restarting the server

I'm working on a website that i built with codeigniter framework. I'm using amazon EC2 instance since last 1 month. Today while doing some work i found that changes done in PHP files are not ...
1
vote
0answers
118 views

Apache authentication with PHP file

Is it possible to have authentication in Apache (or for example Nginx/HAProxy/etc) with a PHP file? What I want is the following: User visits a portal (index.php). Apache will look if index.php ...
1
vote
0answers
178 views

Apache downloading PHP files instead of rendering them after uddate form php 5.3.3 to 5.4

I have some scripts that need to use a newer version of PHP, Im running Debian 6 which has PHP 5.3.3 support, I found I could install php 5.4 using https://www.dotdeb.org/instructions/ packages. This ...
1
vote
0answers
273 views

ERROR 500 - Internal server error on PHP Sites

I am running IIS7.5 on Windows Server 2008 R2 SP1. Over a month ago I did the generic installation of PHP (v5.5.11), MySQL and the phpMyAdmin interface and it all worked great. The other day I started ...
1
vote
0answers
15 views

Anonymous Authentication Identity Win 2012 r2 security

I have a web app that uses PHP on the back-end, and the PHP executes powershell scripts to reset AD passwords through system calls. EX: shell_exec("powershell.exe -file C:\inetpub\wwwroot\script....
1
vote
0answers
92 views

Environment variables for PHP applications

A PHP application requires me to set several environment variables with things like database credentials, SMTP server, etc. Examples of variables include: FOO_DATABASE_URL=mysql://user:pass@host:...
1
vote
0answers
373 views

Why do I get an OpenSSL Error when connecting PHPMyAdmin through SSL?

I'm running PHP 5.6.11 on Apache 2.2 with OpenSSL 1.0.1 on Ubuntu 12. I've sucessfully setup SSL in Apache and MySQL. Now I want to set up a PHPMyAdmin and connect it through SSL. I don't really need ...
1
vote
0answers
252 views

opcache causing errors: Allowed memory size, and malloc: *** error for object 0x10b4cbaf8: pointer being freed was not allocated

Since I installed opcache I am getting these errors: [Thu Jun 04 17:31:02 2015] [error] [client 127.0.0.1] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate ...
1
vote
0answers
50 views

PHP remote network location not appearing

I'm having some difficulty getting PHP (or more specifically, Python via PHP) to recognize an important network location. I'm trying to make a simple website which will allow users to easily execute ...
1
vote
0answers
93 views

Why won't php5-fpm start?

I've just installed php-fpm 5.6.8 but it won't start - start php5-fpm gives me a Job failed to start message. I've found several people with simalar problems, but the none of the answers seem to work ...
1
vote
0answers
17 views

Php load balancing questions

I have a custom written ecommerce app that runs on it's own dedicated server. All of it's constants (such as database connections, file paths etc..) are defined in a single _constants.php file. The ...
1
vote
0answers
130 views

Redis Sentinel false failovers

I'm having problems with Redis. I have 3 servers. Each server have 10 Redises working on different port. Also, each server has one Sentinel instance. Also, there are 5 application servers. Each ...
1
vote
0answers
396 views

Installing php-mysql on centos 6.5 fails due to conflicts when percona client 5.5 also installed

Some background: I'm writing a Chef cookbook to set up a LNMP stack for local development. It requires the php-mysql library for PHP 5.4 (using the php package). We're using the yum-remi repository ...