Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 98133
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T00:08:16+00:00 2026-05-11T00:08:16+00:00

I transfer a fair amount of XML from the server to the client, in

  • 0

I transfer a fair amount of XML from the server to the client, in my application (250K-500K each time).

How can I compress it on the server, and decompress it on the client using standard JavaScript? Is it possible?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T00:08:17+00:00Added an answer on May 11, 2026 at 12:08 am

    First, a scolding and possible workarounds. Second, a possible crazy solution.

    The Scolding

    If you’re sending 250k – 500k back and forth between the client and server, you’re doing it wrong. Look into

    1. Only requesting and sending back the information you need

    2. If there’s information in the XML that doesn’t change often, configure your web-server for aggressive http caching for these requests. Also, consider sending the ‘doesn’t change often information’ down with the initial page request instead of grabbing it from the server

    3. Consider sending down JSON instead of XML. JSON is less verbose than XML and will usually take up less space. If your client-side code NEEDS an XML object, reconstruct it from the JSON you just downloaded.

    4. If you’re using apache, mod_deflate will gzip your data for client that can accept it. Last time I looked into gzip encoding on IIS it did it’s zipping and unzipping on disk, which quickly became a bottle-neck in high load situations (YMMV)

    The Crazy Solution

    If you’re hell-bent on trying the compress-in-javascript route, the LZ77 compression algorithum has been ported to most languages, including javascript.

    Find the analogous code for your server platform, compress the XML, and then feed it to the code found in the link above. To avoid encoding issues, I’d try wrapping the compressed data itself in either XML or JSON when sending it down.

    Javascript compression performance is going to be slow.as.molasses, which is why I discourage this route.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How can I transfer my SQL Agent job (maintenance plan) from my server to
I have a File Transfer Application that sends files and folders. (Server - client)
I need to automatically transfer an xml file from server A over internet to
I need to transfer a database from a SQL Server instance test server to
I want to transfer a large amount of data from F# to an SQL
Im currently wishing to transfer data from a remote server by capturing printed data
Task: transfer a server side binary tree to client. I got this task in
In our File Transfer application the network performance was fair but we want to
I need to transfer some data from SQL Server to MySQL, once a month.
My goal is to transfer entries from one ldap server to another - preserving

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.