You are not logged in.

#1 2017-11-23 09:50:45

starfry
Member
From: Surrey, UK
Registered: 2010-08-18
Posts: 230

[SOLVED] Firefox won't load php from localhost

Strange one this....

I just updated my system and installed apache/php as per the Wiki with the intent of quickly trying something out.

* If I use Firefox to load "http://localhost/phpinfo.php" I am presented with the firefox open/save dialog.
* If I use Firefox to load "http://myhost/phpinfo.php" I am presented with the expected PHP info page.
* If I use Firefox to load "http://127.0.0.1/phpinfo.php" I am presented with the expected PHP info page.
* If I use Qutebrowser to load "http://localhost/phpinfo.php" I am presented with the expected PHP info page.

Firefox doesn't even request the page if the URL uses localhost and all the other tests worked fine - including using localhost from another browser. So I don't think this can be a server-side issue.

Has anyone seen this behaviour ?

firefox 57.0-2
php 7.1.12-1
apache 2.4.29-1
Linux 4.13.12-1-ARCH #1 SMP PREEMPT Wed Nov 8 11:54:06 CET 2017 x86_64 GNU/Linux

Last edited by starfry (2017-11-24 11:27:52)

Offline

#2 2017-11-23 11:09:49

r0b0t
Member
From: /tmp
Registered: 2009-05-24
Posts: 505

Re: [SOLVED] Firefox won't load php from localhost

That's quite weird, if you try an older version of firefox is it working?
Maybe something new introduced with quantum.

Offline

#3 2017-11-23 14:04:07

progandy
Member
Registered: 2012-05-17
Posts: 5,184

Re: [SOLVED] Firefox won't load php from localhost

Did you try to clear the cache in firefox? I did a very quick test on FF57 using the php testserver instead of apache without any problems.

mkdir -p /tmp/testroot
cd /tmp/testroot
echo "<?php phpinfo(); ?>" >phpinfo.php
sudo php -S localhost:80
# in firefox open localhost/phpinfo.php

Last edited by progandy (2017-11-23 14:05:20)


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

#4 2017-11-23 14:06:42

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: [SOLVED] Firefox won't load php from localhost

Also ensure "ping localhost"

Offline

#5 2017-11-24 11:27:37

starfry
Member
From: Surrey, UK
Registered: 2010-08-18
Posts: 230

Re: [SOLVED] Firefox won't load php from localhost

I can "ping localhost". I was using two browsers on the same desktop side-by-side and one worked whilst the other, Firefox. didn't. However, clearing the cache sorted it. So problem solved smile

Offline

Board footer

Powered by FluxBB