jQuery and Colorbox "Is Not A Function"

Posted by Neurofluxation on Stack Overflow See other posts from Stack Overflow or by Neurofluxation
Published on 2010-05-18T13:06:02Z Indexed on 2010/05/18 13:10 UTC
Read the original article Hit count: 1130

Filed under:
|
|
|

Hey you lot, I've been working on integrating Colorbox (a lightbox alternative) into a site.

Ok, so my head file is:

<head>
<script language="javascript" type="text/javascript" src="js/jquery.js"></script></script>-
<link type="text/css" media="screen" rel="stylesheet" href="../colorbox/colorbox.css" />
<script type="text/javascript" src="../colorbox/jquery.colorbox.js"></script>
<script type="text/javascript">
    function saveToBook() { 
        $.fn.colorbox({inline:false, href:'../index.html'}); 
    };
</script>
</head>

My Link is as follows:

<a href="#save-to-book" onclick="javascript:parent.saveToBook();return false;" class="recipe-links">Save to Cookbook</a>

The only output I recieve (from FireBug) is:

$.fn.colorbox is not a function

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about html