Hi Jonny-
Are you using App Engine templates to render the gadget XML?
If so, you could pass in the current URL path to the gadget XML and use that
to form the URL.
You could do:
import os
server = os.environ['SERVER_NAME']
template values = {"server": server}
And then in the template:
<script src="http://{{server}}/bla.js"></script>
That's just one proposal, would be interested to hear others.
- pamela
On Mon, Oct 19, 2009 at 11:44 PM, Jonathan Hunt <[email protected]> wrote:
>
> Hi,
>
> I am running my test version of my gadget on a different version of
> appengine from the deployed version. I just wasted a bunch of time
> trying to figure out why none of my changes were not working before I
> realized that my XML gadget specification references pulls in the
> javascript file <script src ="..."> using an absolute URL so it was
> pointing to the deployed version the whole time. Initially I had tried
> to use a relative URL (the js file and the XML file reside in the same
> directory) but it didn't work. Is there any easy way to do this
> without resorting to server side scripts?
>
> To make things clearer.
> a.com/gadget.xml
> a.com/gadget.js
> at the moment the only way I can find to include the js file from XML
> requires specifying the absolute URL (src="http://a.com/gadget.js')
> but the problem is that if the whole thing is moved to b.com then the
> gadget is still loading a.com js file until the xml specification is
> edited, it would be much nicer if there was a way to use a relative
> URL.
>
> And I want to keep the js seperate for tidyness, debugging etc.
>
> Thanks for any help,
> Jonny
>
> --
> Jonathan J Hunt <[email protected]>
> Homepage: http://www.42quarks.com
> (Further contact details there)
> "Physics isn't the most important thing. Love is." Richard Feynman
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Wave API" 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-wave-api?hl=en
-~----------~----~----~----~------~----~------~--~---