i want to use a jquery widget in my pyramid project. Specifically I want to use a datepicker widget.
I copypasted the jquery datepicker code from http://jqueryui.com/demos/datepicker/ in my template (.pt) file.
<script type="text/javascript">
jQuery(function() {
jQuery( "#datepicker" ).datepicker();
});
</script>
<div class="demo">
<p>Date: <input type="text" id="datepicker"></p>
And I downloaded jquery and I am including its js files like this:
<script src="${request.static_url('eventmanager:static/javascripts/jq/jquery-1.7.1.min.js')}"></script>
<script src="${request.static_url('eventmanager:static/javascripts/jq/jquery-ui-1.8.18.custom.min.js')}"></script>
However, in the page only the text input form appears, with no datepicker calendar, what am I doing wrong?
edit: In my browser javascript console I get the error:
Uncaught TypeError: Object [object Object] has no method 'datepicker'
for when i do
jQuery('#datepicker').datepicker(