Hi,

I should add to that, that you can also use
gadgets.io.RequestParameters.REFRESH_INTERVAL = number of seconds to
cache. This is probably an easier solution, but doesn't appear to be
on that page, yet.

Best,
Dan

On Jan 22, 9:26 am, "Dan (Google Employee)" <[email protected]>
wrote:
> Hi,
>
> Disabling caching with the developer gadget only disables caching of
> the gadget XML, any other functions of the gadget which operate via
> the proxy will remain cached as per their usual parameters. To disable
> or configure caching with makeRequest, follow the example function
> given here:http://code.google.com/apis/gadgets/docs/remote-content.html#Cache.
>
> Best,
> Dan
>
> On Jan 21, 12:01 pm, brookswift <[email protected]> wrote:
>
> > I can't seem to get the makeRequest method read new data. I've set up
> > this simple gadget app to illustrate my problem. Clicking "Get Data"
> > returns the JSON string [28063]. Adding the url parameter ?
> > condition=cancer will return the JSON string [0] in a browser.
> > However, in this application, that query with the added url parameter
> > also returns [28063].
>
> > I have been testing the app on my igoogle dev sandbox with caching
> > turned off for the gadget.
>
> > Is there something I'm missing here? I also attempted using a static
> > txt file as a JSON source, then updating the txt file on my server and
> > refreshing my igoogle dev sandbox to view the updated data, but only
> > got the old data.
>
> > The only way I can get the data to update is to either a) delete the
> > gadget from my igoogle dev sandbox page and reinstall it, or b) update
> > the gadget's xml file and refresh my igooge dev sandbox page.
>
> > <?xml version="1.0" encoding="UTF-8" ?>
> > <Module>
> >   <ModulePrefs title="Fetch JSON Example"/>
> >   <Content type="html">
> >   <![CDATA[
> >     <div id="content_div">
> >         <a onclick="getdata('')" href="#">Get Data</a><br />
> >         <a onclick="getdata('cancer')" href="#">Get Cancer Data</a><br />
> >         <span id="count">count</span>
> >     </div>
> >     <script type="text/javascript">
>
> >     function getdata(string) {
> >         alert(string);
> >       if (string != '') {
> >         var url = "http://76.74.252.152/cgi-bin/count.cgi";;
> >       } else {
> >         var url = "http://76.74.252.152/cgi-bin/count.cgi?"; + "condition=" +
> > string;
> >       }
> >       var params = {};
> >       params[gadgets.io.RequestParameters.CONTENT_TYPE] =
> > gadgets.io.ContentType.TEXT;
> >       gadgets.io.makeRequest(url, response, params);
> >     };
>
> >     function response(obj) {
> >       alert(obj.text);
> >       document.getElementById('count').innerHTML = obj.text;
> >     };
> >      </script>
> >   ]]>
> >   </Content>
>
> > PS. I tried to submit this issue 
> > athttp://code.google.com/p/opensocial-resources/issues/entry?template=i...,
> > but the submit button was disabled and in trying to figure out how to
> > fix it, i lost the bug report that i'd written out.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"iGoogle Developer Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-Gadgets-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to