Issues with 7970 XML caching

Unanswered Question
Aug 10th, 2007

I've been developing a series of services for use on the 7940 and 7970 phones, but when began compatibility testing for the 7970's, i noticed that it caches the content of previous xml pages visited.

Some parts of the services i've created rely on pages always being re-freshed when they are returned to by pressing the exit soft key. Is there any way to enforce a page-refresh on the 7970's?

I'd thought there might be a recognized header-tag to enable this, though using page expiries is clearly out of the question.

Any help would be greatly appreciated.

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 1 (1 ratings)
msabir Fri, 08/10/2007 - 07:44

On the page, that is supposed to expire, add a date header like in this Java code:


Cheers, and don't forget to rate this post :)

john.chillemi Sun, 08/12/2007 - 19:07

I understand how to use page expiries to remove elements from the URL stack, but i'm looking to have an item which will be returned to, but will refresh itself upon return. (This happens on the 7940's automatically, because they have no page caching ability, but the 7970's have a cache, and won't automatically re-load previous pages.)

An example of the header to do this in HTML terms would normally be Pragma = "no-cache" or Cache Control = "no-cache". I'm wondering if they'res a phone-recognised equivalent header. or some other solution. (Neither of the above headers seem to be recognised by the phone.)

stephan.steiner Mon, 08/13/2007 - 00:57

Unfortunately, "response.setDateHeader("Expires",-1); " isn't going to cut it in Java.. it's code that works on IIS. The above would return in an expiration header that is 1 minute before "right now", whereas in Java, the return value is "-1", and you'd like "right now minus 1 minute" instead. I have not found any other way but to construct the time string manually, e.g. like this:

public static String getServerTimeString()


Calendar cal = Calendar.getInstance(TimeZone.getTimeZone("GMT"));

cal.add(Calendar.MINUTE, -1);

SimpleDateFormat sdf = new SimpleDateFormat("EEE, d MMM yyyy HH:mm:ss", new Locale("en", "US"));

String datetime = sdf.format(cal.getTime());

datetime += " GMT";

return datetime;


Since this code is timezone dependant, you might just want to subtract more than a minute (e.g. in my case I'm in timezone GMT+1 so with the summer time, if I subtract 2 hours I'm always on the safe side)


This Discussion