Piece of js code makes all areas below it uneditable

Permalink
Hi,

I am hoping to get some help here.

I have an opt-in form on my page, and in order to pull in the opt-in time I have to use this piece of code here:
<script type="text/javascript">
/*<![CDATA[*/
jQuery(function($) {
                $(".field-type-datetime").datetimepicker({
                    format: "yyyy-mm-dd hh:ii:ss",
                    language: ""
                });
});
/*]]>*/
</script>


The problem is, When I add the coed, all areas bleow the area the code is in become uneditable, and I can't add any more blocks below the block with the code.

This is not theme specific, in fact with most of the themes I tested it, the edit bar also disappears completely.
With my current theme (foundation), I can at least still edit the rest of the page, i.e. all the blocks above the one with the code.

The page console shows this error:

"TypeError: $(...).datetimepicker is not a function
index.php:150:17 <anonym>
http://mypage.com/index.php:150:17...
o
http://mypage.com/concrete/js/jquery.js:2:14728...
fireWith
http://mypage.com/concrete/js/jquery.js:2:15502...
ready
http://mypage.com/concrete/js/jquery.js:2:9592...
B
http://mypage.com/concrete/js/jquery.js:2:14288"...

I am totally no coder, can anyone see what the problem is and if there is a fix for it?
I cannot change the js code, as it works in with my autoresponder.
Seems like c5 is looking for $(...)datetimepicker function in some hp file?

rritz
 
hutman replied on at Permalink Reply
hutman
The javascript function datetimepicker doesn't exist on your site. You need to find out where your opt-in form thinks it's supposed to come from.