Jump to content

V3 Admin-->reports---->clients


PPH

Recommended Posts

For me, if I click on the CSV EXPORTS for clients, it just opens in the browser window, if I choose the products, it promots me to save or open, if I open, it opens in the browser, if I try to save it, it errors out with:

Internet Explorer cannot download ...csvdownload.php?type=products from http://www.domain.com

 

Using CentOS 4.4 on server

WHMCS v3

IE 6 browser

Link to comment
Share on other sites

  • 1 month later...

This is because WHMCS doesn't send a header saying what the name of the file should be so the browser assumes it's the same as the .php file. This is pretty standard, MB does this too.

 

The fix is to send some headers:

 

//// header('Content-type: application/force-download');
header('Content-Disposition: attachment; filename="'.
trim(htmlentities($file)).'"');
header("Content-Length: ".(string)(filesize($full)));
header("Cache-control: private");
header("Content-Description: ".trim(htmlentities($file)));
header("Connection: close");

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated