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

  • Home
  • SEARCH
  • 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 6698929
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T06:38:08+00:00 2026-05-26T06:38:08+00:00

So, is it possible to create archive (/binary array?) ones on server side and

  • 0

So, is it possible to create archive (/binary array?) ones on server side and then send it + run-time generated HTML page. I think it is. And wondering if there’s any libraries for that. Client side especially.

Core questions now are:
1. How to transfer image: as a js variable? Like var imagebinary = "3nmrnmfu5...."
2. How to turn image back from binary format and paste them where necessarily.

Now I’m thinking of using data: URL.

tomfumb suggested a brilliant solution that google uses: one “big” image that got caught into smaller pieces on client.

  • 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. Editorial Team
    Editorial Team
    2026-05-26T06:38:08+00:00Added an answer on May 26, 2026 at 6:38 am

    I think the technique you’re looking for often gets called “CSS Sprites”, and there are quite a few good articles on them around the place (just ask your favourite search engine). There are other methods using Javascript instead, but I quite like the CSS method myself.

    There are quite a good articles at:

    http://www.alistapart.com/articles/sprites

    http://www.w3schools.com/css/css_image_sprites.asp

    and many others.

    The idea is to combine all the images into one larger image, then use CSS to control which parts of the larger image to display in any particular case.

    Say you have four identical sized images, 1,2,3,4 (they don’t have to be identical size but
    it makes the explanation easier

    Combine them into one larger image using your favourite server side image toolkit. Something like GD from PHP, or ImageMagick, or PIL if you’re using Python. Most server side kits have a library that can combine images.

    1234

    Then create CSS rules that will display the relevant part of the bigger image on the client:

    for example:

    div.sprite {  height:100px; width:100px;  }
    #image1 {  background: url(bigimg.png) 0 0; }
    #image2 {  background: url(bigimg.png) -100px 0; width: 100px;}
    #image3 {  background: url(bigimg.png) -200px 0; width: 100px;}
    #image4 {  background: url(bigimg.png) -300px 0; width: 100px;}
    

    and the HTML to display them:

    <div id='image1' class='sprite'></div> 
    <div id='image2' class='sprite'></div> 
    <div id='image3' class='sprite'></div> 
    <div id='image4' class='sprite'></div>
    

    It’s the kind of thing it probably isn’t too difficult to automate.

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

Sidebar

Related Questions

It is possible to create a constant like this: http://haacked.com/archive/2007/09/16/conditional-compilation-constants-and-asp.net.aspx <%@ Page CompilerOptions=/d:QUUX %>
Is it possible to create federated Subversion servers? As in one server at location
Is it possible to create a zip archive using PowerShell?
Is it possible to create a Zip-Archive in Java if I do not want
Hi it'd like to know if it's at all possible create a parametric equalizer
Possible Duplicate: Create a temporary directory in Java Duplicate: stackoverflow.com/questions/375910 Is there a way
Possible Duplicate: Create Excel file in Java How to save output in excel format
Is it possible to create a trigger that will not be in a transaction?
Is it possible to create images with PHP (as opposed to simply linking to
Is it possible to create a REST web service using ASP.NET 2.0? The articles

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.