MozillaZine

Vrs. 54.0 - Problem with PHP "readfile" statement

Discussion of bugs in Mozilla Firefox
r.riccardo
 
Posts: 4
Joined: June 27th, 2017, 12:11 am

Post Posted June 27th, 2017, 12:44 am

Good morning,
I noticed a problem with the new version 54.0 of firefox.
On some of my websites, to download the file, do the following instructions:

Code: Select all
Javascript:

Function attachment (id)
{
  filename = "./php/dwn_all.php? id =" + id;
  size = "width = 0, height = 0, scrollbars = yes";
  Var win = window.open (filename, "", size);
 }

PHP:
....
...
$String = "../configured/allegato.PDF";
Header ('Content-Description: File Transfer');
Header ("Content-Type: application / octet-stream");
Header ("Content-Disposition: attachment; filename = attachment.PDF");
Header ('Expires: 0');
Header ("Cache-Control: must-revalidate, post-check = 0, pre-check = 0");
Header ('Pragma: public');
Header ("Content-Type: application / force-download");
Header ("Content-Length:". Filesize($string));

readfile ($string);
...
...


In the previous version of firefox I never had any problems, now when I run the firefox statement it closes!
On Chrome and IE no problem, the files are opened / downloaded without any problems.

I have also verified that the problem is not just about my PC, but also about all of my clients who have updated to the new version.

I tried in the forum but I did not find anyone with my usual problem .... what's wrong?

Thank you

therube

User avatar
 
Posts: 18716
Joined: March 10th, 2004, 9:59 pm
Location: Maryland USA

Post Posted June 27th, 2017, 9:25 am

Anything related noted in the Error Console (Ctrl+Shift+J)?
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 Pinball CopyURL+ FetchTextURL FlashGot NoScript

r.riccardo
 
Posts: 4
Joined: June 27th, 2017, 12:11 am

Post Posted June 28th, 2017, 12:32 am

No warning in logs.

Continuing with the tests we could see that the problem does not occur on all the PCs on which the new version is installed, but we still have not been able to understand what the difference of settings is between one system and another.
At the moment are all pc with Windows 10 and Windows 7 operating system.

The same problem also occurs on a ministerial site of the Italian revenue agency, but I can not give you the link because it is only possible to access through credentials.
So I'm looking for a public site to give you an example where the same problem occurs.

On my side I have been able to verify that the problem occurs both by downloading files with PDF extensions and XML

r.riccardo
 
Posts: 4
Joined: June 27th, 2017, 12:11 am

Post Posted June 28th, 2017, 2:46 am

I run Firefox in Safe mode and the problem does not appear.
I then restored Firefox and now the problem is gone.

I'm confused .... now i need to restore Firefox to all my clients? ....

Alice0775

User avatar
 
Posts: 2635
Joined: October 26th, 2007, 11:25 pm
Location: OSAKA JPN

Post Posted June 29th, 2017, 10:36 pm

I guess ver 54.0.1 fixes this

r.riccardo
 
Posts: 4
Joined: June 27th, 2017, 12:11 am

Post Posted June 30th, 2017, 12:08 am

I confirm that with the new version the problem has been resolved.

Thank you

Return to Firefox Bugs


Who is online

Users browsing this forum: No registered users and 1 guest