Questions tagged [php]
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.
22 questions from the last 365 days
Score of 2
2 answers
171 views
Moved WordPress site to Windows Server 2022 using direct method for updates
I'm moving a bunch of WordPress sites from Linux to Windows Server 2022. The sites are functioning just fine but I'm getting:
"Some files are not writable by WordPress:
xmlrpc.php
wp-blog-header....
Score of 0
0 answers
50 views
Control panel like Plesk or cPanel vs manual Nginx and Apache setup on EC2 for high traffic PHP and Node.js performance and security
I am planning to deploy a high traffic application on AWS EC2. The backend includes both PHP and Node.js. For PHP I need Apache compatibility due to .htaccess and existing behavior, while Node.js ...
Score of 0
0 answers
347 views
Install Composer under PHP 8.5
I have installed Debian 13 and Frankenphp with PHP 8.5.2. Now I try to install Composer 2.9.5 on that system. That Composer version should be compatible with PHP 8.5.
What ever I do, the Frankenphp ...
Score of 0
1 answer
128 views
HTTP SSE how server hold client connection
I'm using Debian 13 with Nginx 1.26.3 and SSE (Server Sent Event) and PHP.
What I tried to achieve is to have many connections to clients. But I have not all the time something to sent to the clients!
...
Score of 0
1 answer
593 views
During upgrade from PHP 8.4 to 8.5 PDO has stopped working
PDO stopped working after apt update to PHP 8.5 and back to 8.4.
PDO was working with 8.4, why would this update and disable PDO?
How do I get PDO to work again?
I attempted to modify php.ini for both ...
Score of 1
1 answer
195 views
Apache error log not showing error details for php files not found
I'm running Apache 2.4.62 on AlmaLinux with php-fpm 8.3.26, Zend Engine v4.3.26
I migrated this server from CentOS and I'm noticing the error logs for the web server, when an invalid php file is ...
Score of 0
0 answers
298 views
Why is PHP 8 slower than PHP 7 on Windows?
I'm working on moving a site from PHP 7 to PHP 8. All seems to be going quite smoothly, but I've noticed that performance is slower on PHP 8. I'm not fussed about performance being massively better on ...
Score of 3
1 answer
249 views
Per-domain error log for PHP-FPM and Apache
I recently moved a PHP application to a new server. I have multiple virtual hosts, and want to keep separate error logs for each domain. For this reason, on the old server I used the ErrorLog ...
Score of 0
2 answers
304 views
Installing PHP replacing version folder with another label
Every time I install php it creates a folder structure as:
/etc/php/8.3/apache2/php.ini
Instead of "8.3" I want to use a label as "installed" and have a folder structure as
/etc/...
Score of 1
0 answers
102 views
Trying to set HttpOnly but no changes are working
After a PenTest was told to set the HttpOnly flag on all of our cookies.
We have an Ubuntu Server 22.04 & 24.04 LAMP stack with a WordPress website. I have made changes to
/etc/apache2/apache2....
Score of 0
0 answers
138 views
PHP.ini setting not in effect with FPM
I just switched my Nextcloud Apache2 install to use php8.3-fpm (from php8.2 apache module).
Everything works, except NC is giving me the warning that my opcache is nearly full. I can also that the ...
Score of 1
3 answers
1657 views
How to install cURL library for PHP on Windows?
I'm starting with this error:
Call to undefined function curl_init()
Fine, so I go to PHP's php.ini file and uncomment:
;extension=curl to extension=curl
I restart Apache, and?
Call to undefined ...
Score of 0
0 answers
71 views
Google Business Profile API always returns PERSONAL account instead of BUSINESS
I’m trying to fetch my Google Business account and locations using the Google Business Profile API with PHP. I’ve set up OAuth2, got a token, and followed all the steps: oauth_start.php → opens Google ...
Score of 1
1 answer
565 views
PHP-fpm (v 8.3) not using sqlsrv or pdo_sqlsrv on Ubuntu 24.04
My VM running Ubuntu 24.04 is giving an error that it cannot find the driver for SQLServer (aka MSSQL-Server aka sqlsrv). Sure enough, a page with phpinfo(); shows no sqlsrv or pdo_sqlsrv.
Here were ...
Score of 1
2 answers
696 views
How can I fix PHP package conflicts when I using multiple PHP versions?
I am running two versions of PHP 7.4 and 8.4 on an Almalinux server and I'm missing a php function posix_getppid (in Laravel/Horizon).
I've searched and it seems I'm missing a PHP extension/module. I'...