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 7818141
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T06:28:45+00:00 2026-06-02T06:28:45+00:00

Why sometimes I send a image (or CSS, JS, etc) to FTP, they are

  • 0

Why sometimes I send a image (or CSS, JS, etc) to FTP, they are not uploaded (or are cached)?

#container {
    background: url("../images/bg.jpg") no-repeat scroll 0 0 transparent;
    height: 895px;
    overflow: hidden;
}

But with // (../images//bg.jpg), I can see the new image

#container {
    background: url("../images//bg.jpg") no-repeat scroll 0 0 transparent;
    height: 895px;
    overflow: hidden;
}
  • 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-06-02T06:28:46+00:00Added an answer on June 2, 2026 at 6:28 am

    It seems that the files ARE uploaded, but cached by the browser.

    Try reloading with CTRL+F5 in Firefox/IE (other browsers may have different shortcuts) and you should see the fresh file always.

    Resources (JS, CSS, and image files) are somehow more aggresively cached by the browser. While for HTML pages, you will generally have a new HTTP request every time you refresh, for resources, sometimes there will be no HTTP request generated at all. You may see it by looking e.g. at the Firebug’s Net Panel.

    Caching is generally a very tricky topic, a lot depends on the server’s and browser’s settings and implementation.

    Browser-caching is implemented generally via exact URL matching. So, http://someserver/bg.jpg and http://someserver//bg.jpg are two entirely different URLs. However, many HTTP servers will assume that you requested the same content, and will send the content of the bg.jpg file stored on your server root folder (you must see the difference between the URL, and the content linked with this URL).

    If you visited the first URL, it will be cached by the browser. Then, after you upload a new version of the image, a lot depends on the browser implementation of caching, and the cache settings of the server that were sent when you downloaded ‘bg.jpg’ for the first time. For instance, the server settings sent in HTTP response header with the image could have been, that for the next say 1 hour, the image may be cached by the browser, and loaded directly from cache without even asking the server (the server settings may be configured that way to avoid unnecessary traffic).

    The (a bit hacky, but quite frequently used) way to always get a ‘fresh’ version of the file is to add a current timestamp to the request (but it’s generally restricted to server-side generation, or in JavaScript scripts) — doesn’t make much sense in CSS.

    So, at the time I write it, the script will ask the server for
    http://someserver/bg.jpg?1334442703
    but a few seconds later when I refresh the page, it will be
    http://someserver/bg.jpg?1334442711

    Most servers will discard the query string (string after ‘?’), and will simply return the same contents of bg.jpg file for both queries, but since the URLs for the images are different, none of the browsers should read the image from cache.

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

Sidebar

Related Questions

sometimes i see an image not being served when the browser look at www.somesite.com/some_image.jpg
I have a URL, lets say http://www.example.com . Sometimes, I need to send HTTP
I'm using curl to fetch data from many website. Sometimes they send back gzip.
I am attempting to send Base64 image data via ajax to Server. Sometimes all
Sometimes in a floated div. IE6 does not display tags, however it does space
I noticed that sometimes(randomly) my Mootools ajax request gets send twice. The second request
I have a Django application which sometimes needs to send some data through TCP
If I understand right, applications sometimes use HTTP to send messages, since using other
Our project is using Ext-js, and sometimes will send several request to Rails. This
Sometimes it will be a SocketException: Stack trace: at System.Net.Sockets.Socket.Send(Byte[] buffer, Int32 offset, Int32

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.