Android XML Cordova update xml file (database) when it modifies



I build applications in PhoneGap. On the server, I have placed zewnętrzym xml file, which serves me as a database. I managed application cache using the http headers in the xml file



<?php
header("Access-Control-Allow-Origin: *");
$file = 'dbtest.php';
header("Cache-Control: max-age=3600, must-revalidate");
header("ETag: '".md5_file($file)."'");
header("Content-Type: text/xml");
?>


The application deletes the specified time. However, the application should be eagerly read the changes when I change something in the xml file and I upgraded it to the server. ETag already tried, If-None-Match, however, the application I can not send to the server. I tried to convey in the header of the html. Is there still some other method that I have to change the xml file on .json? Thanks


No comments:

Post a Comment