Create and download zip file with AJAX

mod_harbour is an Apache module that allows to run PRGs directly on the web !!!

Create and download zip file with AJAX

Postby Otto » Mon Jan 04, 2021 11:06 pm

Dear Antonio,
How can I compress response json in ajax call.
I think this should be possible with mod harbor.
But then is if sufficient to simply use content-encoding: gzip.
Maybe you have an example.

Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6006
Joined: Fri Oct 07, 2005 7:07 pm

Re: Create and download zip file with AJAX

Postby Carles » Sun Jan 10, 2021 5:10 pm

Otto,

This work is done by Apache transparently. You must activate the mod_deflate in your httpd.conf

To see if your site works there are pages that will help you verify it, such as https://www.giftofspeed.com/gzip-test/

C.
Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
Skype -> https://join.skype.com/cnzQg3Kr1dnk
User avatar
Carles
 
Posts: 1090
Joined: Fri Feb 10, 2006 2:34 pm
Location: Barcelona

Re: Create and download zip file with AJAX

Postby Otto » Tue Jan 12, 2021 1:55 pm

Hello Carles,
thank you so much.
On my server I had to use this test tool:

https://www.whatsmyip.org/http-compression-test

https://www.giftofspeed.com/gzip-test/ give me an error.
On an other serve this is working fine.


Best regards,
Otto

Image
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6006
Joined: Fri Oct 07, 2005 7:07 pm

Re: Create and download zip file with AJAX

Postby Otto » Wed Jan 27, 2021 5:48 pm

Hello Carles,
I made a test with deflate on and off.

Image

Thank you again for your help.

Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6006
Joined: Fri Oct 07, 2005 7:07 pm


Return to mod_harbour

Who is online

Users browsing this forum: No registered users and 9 guests

cron