The page I am having problems with is at http://www.hydeparkny.us/index2.shtml
.  The page that is working is password protected but has the same
javascript as the one that is broken:

<script src="http://www.google.com/jsapi?key=ABQIAAAAAuFv9-
ysRAmlUlKrhnPuhRQc6q9CXVSONpNW0QRAK4JnBvqFSxR9T7e_6KuHO8qDSdId7RvVRVQs4w"
type="text/javascript"></script>
    <script type="text/javascript">
    //<![CDATA[
        var calendarService;
        var feedUri = 'http://www.google.com/calendar/feeds/
[EMAIL PROTECTED]/public/full';
        ... declares for handleError() and displayCalendars() ...
        function setupMyService() {
                window.alert("In setupMyService");
                calendarService = new 
google.gdata.calendar.CalendarService('Town-of-
Hyde-Park');
        }

   function getQuery(URI) {
      window.alert("In getQuery");
      var query = new google.gdata.calendar.CalendarEventQuery(URI);

      var now = new Date();
      var today = now.getFullYear()+'-'+padNumber(now.getMonth()
+1)+'-'+padNumber(now.getDate());
      var then = new Date();
      then.setDate(then.getDate()+7);
      var tomorrow = then.getFullYear()+'-'+padNumber(then.getMonth()
+1)+'-'+padNumber(then.getDate());

      query.setOrderBy('starttime');
      query.setSortOrder('ascending');
      query.setFutureEvents(true);
      query.setSingleEvents(true);
      query.setMaxResults(10);
//      query.setMinimumStartTime(today);
//      query.setMaximumStartTime(tomorrow);
      return query;
    }
        function getCalendars() {
                window.alert("In getCalendars");
                setupMyService();
                var query = getQuery(feedUri);
                // Submit the request using the calendar service object
                window.alert("calendarService.getEventsFeed");
                calendarService.getEventsFeed(query, displayCalendars,
handleError);
                window.alert("back from calendarService.getEventsFeed");
        }
    google.load("gdata", "1");
    google.setOnLoadCallback(getCalendars);

    //]]>
    </script>



On May 27, 2:26 pm, "Austin (Google)" <[EMAIL PROTECTED]> wrote:
> Hi,
>
> The Google Calendar JavaScript client library allows your code to run
> correctly within any domains and it does provide cross-domain technology to
> permit data transfer between your domain and Google Calendar server.
>
> Can you give us a snippet of your code so we can help you identify what
> might be the cause? thanks!
>
> Austin
>
> On Sun, May 25, 2008 at 8:08 PM, Steve <[EMAIL PROTECTED]> wrote:
>
> > First, I am new to the Google API.  I have two domains, each of which
> > I want to be able to access its Google calendar with the javascript
> > Google API.  Each Google calendar is under a different Google
> > account.  Following the samples I was able to access the calendar from
> > the first domain.  I copied that code into a web page on the second
> > domain, changed the Google API key to one for the domain and changed
> > the calendar feed address to the second calendar.  When I visit this
> > page, I get the message 'Permission denied to call method
> > XMLHttpRequest.open'.  I tried using the calendar feed address of the
> > second calendar in the page on the first domain and that worked.  I
> > mostly use Firefox 2 but I also tried IE7 and that had the same
> > problem.  I've seen the postings about cross domain access but I don't
> > understand exactly what it means.  I'm hoping it doesn't mean you can
> > only ever visit one page that uses the calendar API to display Google
> > calendar info.
> > Any help would be appreciated.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Calendar Data 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-calendar-help-dataapi?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to