Skip to main content

Bug Tracker

Side navigation

#10972 closed bug (worksforme)

Opened December 07, 2011 01:09PM UTC

Closed December 07, 2011 05:01PM UTC

Last modified December 09, 2011 12:48PM UTC

AJAX cache option for scripts is ALWAYS false

Reported by: Youri Owned by:
Priority: low Milestone: None
Component: ajax Version: 1.7.1
Keywords: Cc:
Blocked by: Blocking:
Description

To improve performance my a website, I tried to allow caching of several JS files, which are loaded via $.ajax().

To do so, I added the option cache:true.

But when I examine the response headers (chromebug/firebug), I find that jQuery still added headers as if cache was false.

Maybe the cache checks only check if cache is explicitly set to false? (Since that is the only check needed for any AJAX call, except script/jsonp).

Youri

Attachments (0)
Change History (3)

Changed December 07, 2011 01:12PM UTC by Youri comment:1

EDIT:

I have not added a testcase since I would have to use a crossdomain request on jsfiddle, which might influence the results.

If I'm wrong here or anyone has a way of testing this, please do tell me or test it.

Changed December 07, 2011 05:01PM UTC by timmywil comment:2

component: unfiledajax
priority: undecidedlow
resolution: → worksforme
status: newclosed

http://jsfiddle.net/timmywil/br2BG/

Note that the query string is not manipulated.

Changed December 09, 2011 12:48PM UTC by Youri comment:3

Terribly sorry something else messed up for me. This can be closed.