Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

How To Create Button In Addons Setting Page Rate Topic   - - - - -

 
  • mikalim
  • Newbie
  • Trial users
  • Join Date: 21-Jun 21
  • 2 posts

Posted 12 July 2021 - 03:17 AM #1

Hi,

 

I am trying to add a button in my addon's setting page. It is a download button. 

I will pass the file name via link, and if the $_GET['file'] is same name with my log file. I will download the log file.

 

But now when I click download button, it's showing the content instead of downloading the file.

 I think download file code is working due to when I using it without any condition. It's able to download when installing the addon.

 

Hope anyone can help me on this issue. 

 

Thanks and Regards,

Mika



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 21996 posts

Posted 20 July 2021 - 01:22 PM #2

Use custom controller and add necessary headers before returning file


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    Multi-Vendor PLUS           USD 3100 (2775)
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      Multi-Vendor Ultimate       USD 7500 (6000)