| Issue 745: | Installation trouble - '$('#calendar').fullCalendar' [undefined] is not a function | |
| 1 person starred this issue and may be notified of changes. | Back to list |
I'm having trouble getting a calendar set up on my site. It's a Drupal site, but I'm not using the fullcalendar Drupal module because I want to display a Google calendar. My HTML follows the example pretty closely: <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> ... <script type="text/javascript" src="/misc/jquery.js"></script> <script type="text/javascript" src="/misc/drupal.js"></script> <script type="text/javascript" src="/misc/collapse.js"></script> <link rel='stylesheet' type='text/css' href='/misc/fullcalendar/fullcalendar.css' /> <script type='text/javascript' src='/misc/fullcalendar/fullcalendar.js'></script> <script> $(function() { $('#calendar').fullCalendar({ // put your options and callbacks here }) }); </script> ... </head> <body class="not-front logged-in page-node node-type-page one-sidebar sidebar-left col-2 "> ... <div id='calendar'></div> However, no calendar appears, and in Safari's error console I see "TypeError: Result of expression '$('#calendar').fullCalendar' [undefined] is not a function." In the console I can verify that $('#calendar') does return a div node. I'm using JQuery 1.3.2, JQuery UI 1.6, and Drupal 6.19. Any hints greatly appreciated! -Ken
Dec 3, 2010
Project Member
#1
althaus.it
Dec 3, 2010
Well, I think so - I can manually visit /misc/fullcalendar/fullcalendar.js and it loads. Some other way to verify? You're right that it's acting like it's not loaded.
Dec 3, 2010
The problem seems to be with this snippet at the end of the page: <script type="text/javascript" src="/sites/all/modules/jquery_update/replace/jquery.min.js?E"></script> If I remove that, the calendar starts working. I guess I don't quite understand what this line is for, though, it seems to be added automatically by the jquery_update module, so I don't want to (nor would I know how to) get rid of it. Any suggestions?
Dec 6, 2010
If this is a problem of Drupal, you should look there for help as this here wouldn't be the right place.
Dec 6, 2010
Yeah, it does look like a Drupal problem now, feel free to close this.
Dec 26, 2010
(No comment was entered for this change.)
Status:
Done
|
|
| ► Sign in to add a comment |