views:

74

answers:

2

Sorry but I can't seem to get my special-kid helmet off today. I'm attempting to use Full Calendar http://cl.ly/1UCt ... I've verified that there are no relevant javascript errors, all of the scripts are being called properly, I have a #calendar div, yet I'm getting no results or output on the page.

Using this within WordPress, here is my relevant header:

    <link rel="stylesheet" type="text/css" href="<?php bloginfo('template_url')?>/fullcalendar-1.4.6/fullcalendar.css" />
    <script type="text/javascript" src="<?php bloginfo('template_url')?>/fullcalendar-1.4.6/jquery/jquery.js"></script>
<script type="text/javascript" src="<?php bloginfo('template_url')?>/fullcalendar-1.4.6/fullcalendar.min.js"></script>
    <script type="text/javascript">
        $(document).ready(function() {

            // page is now ready, initialize the calendar...

            $('#calendar').fullCalendar({
                // put your options and callbacks here
            })

        });
        </script>

And you can view the page itself (with non-existent calendar) here: http://cl.ly/1UKk

Any suggestions for debugging / troubleshooting? I have no idea what's wrong here...

EDIT: As pointed out by Charles below, it seems like the function fullCalendar is undefined. I'm just following the basic callback parameters for the script, does anyone have an idea why it would be undefined? I haven't changed anything from the default/basic callback.

+1  A: 

Chrome's Javascript console says:

Uncaught TypeError: Object # has no method 'fullCalendar' (classes:37)

Line 37 is your $(...).fullCalendar() line.

Running just $('#calendar').fullCalendar(); at the console results in the same error.

I'm not completely sure where to troubleshoot this one from here because I don't know the plugin at all. I'd start by switching to the non-minified version of the plugin and see if that makes a difference.

Edit: FWIW, I've had the darndest time getting real errors inside $(document).ready in Firefox. I'm not really sure what's up with that.

Charles
Great, that gives me something to work with, however, I'm not much of a JavaScript pro, I haven't done anything to alter the defaults. Why would the basic callback for the script not be recognizing it's own function (found in this script: http://cl.ly/1USu) ?!
Brian
A: 

It turned out to be a jQuery conflict. I've got alot of scripts running on this page and there were actually two conflicts, one because of calling jQuery at the top and bottom of the document. The second was because of a Web Form from MailChimp which also calls javascript.

Brian