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.

Filter by
Sorted by
Tagged with
0
votes
1answer
144 views

How to install PHP 7.4.3 on CentOS 8?

I need to upgrade to PHP 7.4.3 (from 7.4.14), and I have somehow managed to make no progress after many, many hours. *Needed for MediaWiki, Roundcube and PostfixAdmin. Two questions: Do I have to ...
1
vote
0answers
45 views

Use HTTP/2 together with PHP SQLSRV extensions?

I have a web site (Apache/2.4.46, HTTPS) using PHP7.3, MariaDb 10.4, MSSQL for Linux (mcr.microsoft.com/mssql/server:2019-latest), running on a Debian 10 server. My setup works perfectly using HTTP/1....
2
votes
2answers
183 views

Error Phpmyadmin

i have this problem after updating ubuntu. It asked me if I wanted to update the configuration that it already had, and I said no. phpmyadmin was working correctly before the upgrade. If anyone knows ...
0
votes
1answer
182 views

php will not allow me to do `shell_exec('git pull origin master 2>&1');`

When I run the script <?php chdir('/var/www/html'); echo shell_exec('git pull origin master 2>&1'); ?>, I get the error message: error: cannot open .git/FETCH_HEAD: Permission denied ...
1
vote
2answers
57 views

How do I make my PHP Source installation use the libraries inside of /usr/local/programname/lib instead or /usr/local/lib?

How do I make my PHP Source installation use the libraries inside of /usr/local/programname/lib instead or /usr/local/lib? I have tried setting LD_LIBRARY_PATH to each of the program names like ...
0
votes
1answer
70 views

How to serve TFTP content via script (PHP-like)?

I am looking for a way to serve TFTP requests with an output from a script (bash, PHP?) called with the TFTP request path as an argument. A simple TFTP equivalent of Apache+PHP. Something like PHP + ...
1
vote
1answer
335 views

CORS conflict after enabling FPM in PHP

In the .htaccess file on my web server, I have the following CORS header set: Header set Access-Control-Allow-Origin "example.com" In one of my PHP scripts, that I frequently call while ...
0
votes
0answers
46 views

Prohibited Y0u don't have permission to access this resource

My laravel website gives me an error after changing one piece of code from a comment to code back to a comment again in the .htaccess file. I've tried I think everything with the folder permissions ...
0
votes
1answer
79 views

How to debug an unreachable (from the wan side) lemp server tunneling through an AWS based Openvpn-AS instance

Ive been wracking my brains out for weeks trying to debug a once perfectly functioning LEMP web server. I'm using a relatively complicated setup. Lets start with my setup from the beginning when ...
0
votes
0answers
1k views

MariaDB Error Reading Communication Packets

I have a problem. When I split my MariaDB from main server to another server (my database server is running MariaDB docker from latest tag) I got an error: Got an error writing communication packets ...
0
votes
0answers
30 views

mount directory in docker container for nginx-webserver, using docker-compose // Piwigo Nginx NAS Docker

I'm trying to mount a specific directory from a docker host system to a Nginx-Webserver, using docker-compose, but I couldn't reach the expected content in the web application (Piwigo Photo-Gallery). ...
0
votes
1answer
1k views

Can't 'php artisan migrate' inside docker

Trying to run 'php artisan migrate' in docker returned following error Illuminate\Database\QueryException could not find driver (SQL: select * from information_schema.tables where table_schema = ...
0
votes
1answer
505 views

Running ansible from webserver to manage infrastructure

I have nginx with php app. I have also installed ansible and copied playbooks on this server. What I want to do is run ansible playbooks through webapp. I want to know how to do this safe way. Nginx ...
0
votes
1answer
36 views

How to redirect old PHP scripts in NGINX configuration to a new HTTPS site?

I have a problem, I'm trying to catch all PHP scripts except one in my NGINX configuration for my HTTP domain configuration: I have a general rule for all PHP files location ~ \.php$ { ...
0
votes
0answers
68 views

Apache access log not logging content-length for data served via PHP

I have a php script that handles files downloads, it sends content-length header properly and the browsers receive it. But in the Apache access log they show up as "-". In the past this used ...
1
vote
1answer
2k views

pecl: command not found when trying to install PHP SQL Server driver

I need to be able to access MSSQL databases from PHP and I'm trying to activate the driver to do so, since mssql php natively was removed after PHP 5.6. Here's what I tried: sudo su curl https://...
0
votes
1answer
94 views

Format for second drive in Linux Server and path to directory in second drive for PHP

I'm working for an office in primary education and I'm setting up a local server with Ubuntu Server 20.04. I have some web applications written in PHP for this server. I am relatively new to Linux and ...
0
votes
0answers
34 views

Why does classic asp or php upload file name have _Conflict in server2019/iis10?

I recently changed the server from win server 2008 to win server 2019 Now I have a problem. Whether it is classic asp or php uploading pictures, they will generate a file like ...
0
votes
1answer
1k views

How to install PHP 8 in Oracle Linux with Apache?

How to install/configure PHP 8 with Apache in Oracle Linux? I couldn't find PHP 8 related repos in Oracle Linux. What i tried so far is: Installed PHP 8 manually by downloading tar. installed httpd ...
1
vote
1answer
39 views

Apache2 Server Huge response time

I am hosting my website in a Gcloud Compute Engine instance in the 'us-central1-a' zone and I'm trying to access the website from Spain, but its response time is about 20s. I believe it's a problem ...
1
vote
0answers
98 views

How to find malicious PHP script that sends emails from my domain?

My organization mail has been blocked by a malicious PHP script for several days. I learned that spam messages are sent via the mail() function. How can I find and delete this script on my server? I ...
0
votes
1answer
268 views

PHP fsockopen giving error with SSL

I am getting the error while connecting to fsockopen. echo $result = fsockopen('ssl://smtp.gmail.com', 465, $error_no, $error_message, 5); //$result = fsockopen('tls://smtp.gmail.com', 587, $error_no, ...
1
vote
0answers
166 views

Mysql in Nginx takes over 100% CPU

I have a Laravel application running on my Ubuntu 18.04 server and MySql 5.7. Sometimes, it is very slow. I have checked with "top" command and this is the result: Some times %cpu raises ...
3
votes
1answer
170 views

Configuring mailiers in Phabricator

After a clean installation using the bitnami image I followed the instructions to set up the mailers. It looks like this: [ { "key": "stmp-mailer", "type": &...
0
votes
0answers
1k views

Laravel Mailtrap SMTP Crack

I have an older Laravel 5.7 project handed to me. Laravel's current version is 8. I don't know if these details are relevant to my problem, but I'm adding them anyway. I have a test server running off ...
0
votes
1answer
38 views

Is there a webpage which tells me when the next version of PHP is planned for release? [closed]

Before PHP 8.0.0 was released, I was eagerly awaiting it. It had an elaborate table detailed the planned release dates for the "GA" (final) version as well as all the betas/alphas/RCs. I ...
1
vote
0answers
55 views

How do I configure an Apache 2.4 virtual server to run a perl script

Using webmin I setup an Apache virtual server under ubuntu 18.04. Server directives are: DocumentRoot /home/name/public_html ServerName www.name.com <Directory "/home/name/public_html">...
0
votes
0answers
244 views

AWS EFS plus PHP painfully slow possible alternatives?

i built an highly available and fault tolerant Wordpress site on AWS Cloud, i using ubuntu 20.04 and apache2.4, /var/www/html is mounted on EFS filesystem configured whit provisioned troughtput at ...
-1
votes
1answer
4k views

Homebrewed http start fails on macOS Big Sur [closed]

I had installed Apache 2.4.46 on macOS Big Sur via Homebrew. It had worked fine until I did brew update and brew upgrade. At this time, PHP was upgraded from 7.4 to 8.0, so I modified httpd.conf as ...
0
votes
3answers
372 views

How to tell .htaccess to only allow requests to index.php and app/dist/* folder?

This is the current folder: /app /dist /index.html /index.css /index.js /src /configurations.json /index.php /configurations.php I have sensitive data everywhere: app/src/... /......
0
votes
1answer
384 views

Very bad ImageMagick resizing performance after upgrade from PHP 5.5 to Docker + PHP 7.4

I’m upgrading some system from PHP 5.5 (installed directly on AWS EC2), to PHP 7.4 in Docker (running on AWS EC2 using Docker Compose). The performance for image resizing using ImageMagick has ...
0
votes
1answer
120 views

Factors of slow TTFB comparing between two VPS providers

I set up two VPS with the same (databases and hosting control panel). VPS company 1: based in california | 1 gbs | 2 core intel(R) Xeon(R) | 2 gb Ram | using Cloudflare VPS company 2: based in ...
0
votes
0answers
82 views

-bash: /usr/local/bin/php: operation not permitted

Why I am unable to execute any command that requires php. For instance [root@server ~]# composer -V "/usr/bin/env: php: Operation not permitted" Here is the permission on where composer is ...
0
votes
1answer
841 views

php-fpm Detected unsafe path transition error message. How?

I know very little about linux/ubuntu, but I needed it for a webserver I am wanting to run. I got everything setup and running nice and I have been getting this for some time now. Every time I attempt ...
0
votes
0answers
39 views

install Fileinfo extension m imap extension

i have an issue when install Mailwizz , i see missing File info extension , IMAP Extension php version : 7.2 OS : Ubuntu 16.04 i tried to install using below code (sudo apt install php-imap) after ...
0
votes
1answer
565 views

Docker NGINX + PHP-FPM : Error 502 Bad Gateway

nginx site conf: server { listen 80; listen [::]:80; server_name example.com www.example.com; root /var/www/example.com; location / { index index.php index.html; } ...
1
vote
0answers
216 views

Long time running PHP script on Apache with separate MySQL server restarting without manual refresh

We're currently making a migration and experiencing a problem we're curious on solving correctly. Our setup is a separate web server running Apache 2.4 and a database server running MySQL 5.7. We have ...
0
votes
2answers
163 views

How to stop requests on PHP server while it is running cron job sheduled PHP script?

I have a situation when some DDOS attacks are putting my PHP server down. Occasionally. I'm using AWS with auto scaling groups, so it is not a problem. The problems start when this server is going ...
0
votes
0answers
27 views

Nginx Overwriting open_basedir issue

I found a line of code that helps preventing include() and such to read out files outside the root folder fastcgi_param PHP_VALUE open_basedir=$document_root; This would apply globally though, so I ...
0
votes
0answers
32 views

Outgoing Mail not working after changing port 25

I want to block Port 25 as my IP got blacklisted multiple times due to some spammers using my server. I've changed the Port to 578 in Postfix and restarted postfix & on top I've as well changed ...
0
votes
1answer
163 views

php_http.dll not Found on Windows 10 Machine

So, I'm pretty stumped on why PHP can not find the php_http.dll extension that I put in my ext folder. I am currently using PHP 7.2, and I am working locally and using PHP's built-in web server. I ...
0
votes
0answers
77 views

Intermittent 504 Error in Apache Web Server in Docker

I am hosting a mapping web site on Apache 2.4 web server sitting in a docker container on an AWS EC2 instance. The website utilises PHP. Ever since I moved the Postgres database off the EC2 instance ...
0
votes
1answer
27 views

Error establishing a database connection on a fresh Wordpress installation

I've installed a fresh copy of Wordpress on CentOS 7/Apache but am getting the dreaded "Error establishing a database connection" error message when navigating to the site to complete the ...
1
vote
1answer
102 views

Multiple long running mysqld processes

today i've checked our server status with htop and i saw somethig that i could not believe. Could someone please answer me the following questions? Why are there so much mysqld processes? Why they ...
0
votes
1answer
46 views

laravel shows error when sending email using tls and my own postfix/virtualmin server

We have installed our own postfix/virtualmin server and we have a laravel application,the problem is when we use external smtp servers, it is not problem to use tls option, and the emails are getting ...
0
votes
1answer
579 views

Powershell module import not persisting in docker container image

I installed powershell in the php debian docker image and now I am installing PowerCLI module in the docker image to access the vsphere info and display using laravel. The issue is with the PowerCLI ...
0
votes
0answers
45 views

PHP error_log is not logging 500 errors

Windows Server 2016, IIS, PHP 5.6.31 I've temporarily set my error_report to E_ALL, and I've restarted my web server in IIS, to help me figure out why I'm getting a 500 error. error_reporting = E_ALL ...
0
votes
1answer
203 views

Original php mysql extension for php56

First a note: Yes, I'm well aware this extension in deprecated and has a ton of security flaws, I'm duplicating a clients active server in docker for recovery and migration (after client's server was ...
2
votes
1answer
51 views

MariaDB 10.2.35 Memory Spikes

On an AWS EC2 T3.large instance I'm hosting a website built with the Cake PHP framework. It utilises the MariaDB version 10.2.35. I'm having an issue whereby the memory for the server is spiking. When ...
0
votes
1answer
838 views

Error: Invalid command 'php_flag', perhaps misspelled or defined by a module not included in the server configuration

I have the very same setup as shown in this thread and I'm having the same exact problem. I've already retraced my steps several times over the installation process of the PHP + Apache + PostgreSQL, ...