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
53 views

How can I “spy” on an Apache web server's response to server-side code like PHP or JavaScript?

I'm trying to debug a problem with a file upload strategy and don't know whether there's an issue with directory permissions / ownership or the scripts. ... I've tried both PHP and JavaScript and can'...
0
votes
0answers
41 views

How to configure Apache to work with current version of PHP?

The problem can be simply shown. My goal is to overcome this error message: http://jfknumbers-forum.org/phpBB3/ Error Message from phpBB application I made a HUGE mistake attempting to build Apache ...
1
vote
1answer
13 views

php geoip not working on ubuntu 18.04

I can't get the GeoIP PHP extension working on Ubuntu 18.04 with PHP 7.2 i have intalled it by the cli: sudo apt-get install -y php7.2-geoip Its enabled in system but not working: php7.2 -i | grep ...
0
votes
1answer
36 views

Can't set open files limit for user www-data and process PHP in ubuntu 16.04

I am having trouble setting the open files limit for user www-data and process PHP in Ubuntu 16.04. I have set all the following to 65535: /proc/sys/fs/file-max /etc/sysctl.conf /etc/security/limits....
0
votes
0answers
24 views

Azure PHP Linux app - URL rewrite issue

We recently deployed an Azure App Service as code, in a Linux environment with a PHP stack. So far everything worked fine but as often required the web developers wanted to enable URL rewrite for the ...
0
votes
0answers
22 views

Premature end of script headers: ea-php73 - cPanel

Whenever I'm POSTing really large request body through a form, my hosting webserver throws 500 internal server error. Upon checking the apache logs I get this: [Thu Aug 06 06:57:28.280888 2020] [cgi:...
0
votes
0answers
31 views

js files occasionally failing to load

We have a newly configured php7 16cpu 32gb RAM Linux server. Plenty of power for what we need. We have a basic form on a page that requires a login. However, sometimes when a user lands on the page, ...
0
votes
1answer
18 views

Two php-fpm processes running after trying to update php version. Wordpress using the wrong one

My Server is running on Google Cloud Platoform: Linux INSTANCE_NAME 4.9.0-11-amd64 #1 SMP Debian 4.9.189-3+deb9u2 (2019-11-11) x86_64 GNU/Linux I installed php 7.3 but in wordpress it still says ...
0
votes
1answer
66 views

Why returns apache a http 500 but does not log any errors?

On a 12 year old (web) server is still 1 old (custom) PHP application hosted. We want to shutdown this server and remove it from the rack. Unfortunately we still need the application, is not actively ...
0
votes
0answers
44 views

Number of MySQL connections spikes, but no spike in number of queries

I am running LAMP stack with CakePHP and MySQL compatible AWS Aurora instance. The Aurora instance is set up with a writer and read replica. Using CakePHP request routing, the read replica is only set ...
0
votes
0answers
48 views

Apache + PHP : End of script output before headers

I was getting the following error occasionally. I've search through stackoverflow but all are due to other issue (either cgi or permission) If i can load the following page occassionally (about ...
1
vote
1answer
27 views

Simple deployment to Ec2

I have a fairly simple PHP application (CakePhp) that has been moved to the clients EC2 account. I'd now like to set up a simple deployment process for it. These are the steps I want: Deploy changes ...
0
votes
1answer
45 views

Restarting Apache with PHP

How would I go about restarting Apache with a PHP script while keeping correct security measures on a production server? This is because restarting Apache requires the use of sudo or root privileges, ...
0
votes
0answers
10 views

Moving from PHP-FPM ondemand to dynamic [duplicate]

current FPM dashboard pool PS process manager ondemand start time 25/Jul/2020:18:25:24 +0100 start since 332382 accepted conn 2981219 ...
0
votes
0answers
29 views

Can't execute PHP via browser on Centos 8

I already installed Apache 2.4 and PHP 7.4 on Centos 8, which is running on Google Cloud Platform. Apache: ● httpd.service - The Apache HTTP Server Loaded: loaded (/usr/lib/systemd/system/httpd....
0
votes
2answers
70 views

Why a PHP module is not loaded into PHP?

Showing my case how to debug the problem, that a PHP module is not loaded into PHP. I use OpenSUSE v42.2 Linux OS, with Apache webserver, PHP v7.1, Mysql. Because it does not provide PHP v7.1 I need, ...
0
votes
1answer
18 views

nginx + php 5.6 serving empty pages, can't find error log

I have accidentally hosed a VPS which was hosting a website using nginx and PHP 5.6, and I'm attempting to recreate things on a new server running Ubuntu 18.04 (previous one was 12.04 - upgrade failed ...
1
vote
0answers
50 views

proxy_fcgi:error AH01071: Got error 'Primary script unknown, Apache + PHP 7.3.2

I'm using my companies Docker Template to try and connect to Localhost, but I get the message "File not found" when inputting localhost:8888 into chromes URL bar. After running the command &...
1
vote
0answers
68 views

Multiple “Location” sections with different handlers aren't combined anymore in apache2 after upgrade

I have a website with the following configuration: <VirtualHost *:80> ServerName example.it <Location /> SetHandler uwsgi-handler uWSGISocket /var/sitedir/moin.sock </...
0
votes
1answer
31 views

How to detect how an intruder is gaining access to my server? [duplicate]

I previous asked this question on StackOverflow. I was recommended here for help. There are some more details on that question. Someone has somehow gained unauthorized access to my website. They have ...
1
vote
1answer
30 views

Legacy php app - what's the correct order to update things? [closed]

I have a legacy PHP application running on: HTTP 1.0 Apache 2.4.10 PHP 5.4.45 MySQL 5.5.42 I have an open source framework which the previous team have manually been writing changes into, so we ...
0
votes
0answers
21 views

Loading site within a site

I have a question because I'm not sure how to approach this and don't know if my thinking is correct. I have a Linux Server (CentOS/RHEL 7). On that server I have an application - r-shiny. It creates ...
0
votes
1answer
41 views

Installing Two PHP version in Centos 7

I need to run two PHP version in my centos 7 server. I am currently using PHP Webstatic repo for installing PHP and using apache. I just gone through the internet and most of them are using Remi repo ...
1
vote
1answer
73 views

How can I get my server to execute (instead of displaying source for) PHP?

I am having trouble getting PHP to be executed instead of treated like plain text. I'm on a new Debian 10 development server, and have installed e.g. apache2 and libapache2-mod-php, which installed ...
1
vote
0answers
39 views

Nginx downloading specific PHP file instead of executing

I moved a small bundle of scripts from Apache to Nginx. This is a directory full of files, where specific extensions (php, txt, js, html) need to be shown through one script, other files need to be ...
0
votes
0answers
15 views

Cronjob stopped working. But cron and php script still work? [duplicate]

I did a ImageMagick install on my CentOS webserver and afterwards my cronjobs do not work anymore. I have cronjobs that executes php files. For example one cronjob execute every 15 minutes a php file ...
2
votes
0answers
22 views

How do I secure my PHP forms that communicate with my MySQL Server? [closed]

They are just the basic forms, they take in $input from the form and then store that directly in to the database, there is another form where it takes $input and searches for a hashed match for it. ...
0
votes
1answer
33 views

Nginx POST request is changed to GET when using Ajax

I have an Nginx server used for a store. That store has an API which is in a different folder for which i'm using an alias. Here is my example.com from sites-enabled in Nginx: server { listen 443 ...
0
votes
3answers
56 views

why do you need to update a whole operating system to get updated php version? (debian) [closed]

I am mostly a windows guy. I have a debian 9 VM with OMV and wanted to update the php version. I read and realised that you need to update the whole os to get the latest php version? Why do you need ...
0
votes
1answer
39 views

Why aren't my PHP-FPM children transitioning back to idle as soon as the request is complete?

I'm trying to debug server lockups when running a Laravel application on K8s. I've got 2 pods each with 100 static children and I'm running a load test. As expected, as the load is applied the ...
1
vote
1answer
30 views

PHP & lighttpd: Cannot access POST data

I am running PHP 7.2 fpm with lighttpd/1.4.53 on Raspbian. My goal is to upload image files through HTTP POST - But whatever I post to the script, the $_POST, $_FILES, $_REQUEST superglobals are just ...
0
votes
1answer
20 views

Get full list of errors associated with stream_socket_client() in PHP

https://www.php.net/manual/en/function.stream-socket-client.php The PHP function stream-socket-client() gives back errors as: errno: Will be set to the system level error number if connection fails. ...
1
vote
0answers
24 views

install php5 but keep php7

I have upgraded, built a new one, my server (Ubuntu 18.04.6) which is running PHP Version 7.2. I would like to install PHP5 and keep PHP7 and have the option to switch back and forth. Have a site that ...
0
votes
1answer
52 views

Directory index of /var/www/html/opencart is forbidden Nginx

I have install multiple php frameworks (Cakephp and Opencart) on nginx web server. Cakephp is working fine in root directory. Opencart is in subdirectory in where i am getting errors. Here is my nginx ...
1
vote
0answers
18 views

Apache with PHP-FPM intercepting errors and not displaying my friendly PHP error page output in dev environment

There is so much static around this it's hard to find an answer that actually applies, so my apologies if there is an answer for this, I just haven't been able to find it. My situation is that I want ...
-1
votes
2answers
42 views

PHP not connecting to my database on Linux? [closed]

I use mariadb as my database and phpmyadmin to access on databases web on Linux. Although I am able to connect to the database on the commandline as root but cannot check connection to the database ...
0
votes
2answers
623 views

Diagnosing apache cpu / memory / process spike

I have a server running Ubuntu 18.04 which has been experiencing huge CPU spike that nearly brings Apache to a halt once or twice a day. The server runs a couple of websites - all php & mysql ...
0
votes
0answers
44 views

autoscaling php-fpm in AWS ECS

I have a t3.medium instance managed by ASG and used by ECS. My application requires approximately 25% of the capacity of this instance to operate at a minimum. will work in the standard nginx + ...
0
votes
1answer
24 views

my website is close “ HTTP ERROR 500 ”

my website is close error is " www.worldtourjourney.com is currently unable to handle this request. HTTP ERROR 500" please help me how can i resolve this error ? My website appears to be ...
0
votes
1answer
27 views

Run incoming mail through PHP script - Postfix

I have followed this answer Pipe all Postfix email for a domain to PHP script - Centos7/EC2 to direct incoming mail for a specific address to a PHP script. My aliases file entry looks like: mail-...
0
votes
0answers
22 views

Dealing with IDM (internet download manager) connections to server and rate limiting

I run a file hosting platform, and am struggling to work out how to handle IDM (internet download manager) connections. When a file is requested, I create a download token, which expires after 10 ...
1
vote
2answers
114 views

How did shared hosting providers ensure user isolation before containerization went popular?

Around 2000-2010, shared hosting was extremely popular as a cheap solution (sometimes a few $ / month, or sometimes even free for just a few MB) for people starting blogs, small websites, e.g. using ...
0
votes
0answers
99 views

How do I resolve this dependency resolution error in yum?

When I run yum update, after dependency resolution I get the following error: --> Finished Dependency Resolution Error: Package: php71w-pecl-imagick-3.4.3-1.w7.x86_64 (@webtatic) ...
0
votes
0answers
12 views

Apache file write buffering?

I have migrated a few WordPress websites from a shared hosting to a VPS. WordPress has an option of redirecting PHP errors from the regular error.log to its own debug.log file. Now I have a problem: ...
0
votes
0answers
14 views

mariadb php connection error (110)

I have a mariaDB service running on a remote server A. I have a second remote server B running httpd. Both server A and B's NAT firewall allows all traffic for port 3306 and ICMP. Server B allows port ...
0
votes
0answers
27 views

How to troubleshoot database writing process via admin-ajax.php in WordPress?

I have siteA.com (live) and siteB.com (staging) which both are identical WordPress sites sitting in a single EC2 server using Webmin with CentOS, MySQL, PHP. The issue is that when I perform the same ...
0
votes
0answers
11 views

Unable to install mbstring for php7.1 on server running multiple PHP versions

My Centos6 webserver is running php 5.6 and php 7.1 (webmin/virtualmin). I already have mbstring installed for php 5.6, but I also need it for 7.1. When I do yum install php71w-mbstring I get the ...
0
votes
1answer
879 views

How can i use two different php-fpm pools depending on url

I would also like to use 2 php-fpm pools. My directory structure looks like this: /home/test/index.php /home/test/contact.php /home/test/stats.php document root is: root /home/test; When I call the ...
0
votes
0answers
22 views

Ubuntu 16 nginx fastcgi_pass php7.0-fpm.sock

I got a wierd head-scratching problem. /etc/nginx/sites-enabled/default has fastcgi_pass unix:/run/php/php7.0-fpm.sock; but the error log refers to php7.1-fpm.sock 2020/06/10 17:44:27 [crit] 7177#...
1
vote
1answer
62 views

Error Log for Apache, PHP, and Codeigniter

In our Apache access logs, we've noticed users occasionally getting a 500 error. It is likely a database query problem within our CodeIgniter code. We can't be sure how to fix it until we see the ...

1
2 3 4 5
149