1

I created a channel form for submitting events here. It shows fine in Safari and Chrome but does not appear in Firefox. I confirmed that the channel permissions are set to allow Guest Publishers, so that is not blocking it.

In addition, the Date selection popup is not working. I added the following required stylesheet link to the template, but it does not make a difference:

<link href="{path=css/_ee_channel_form_css}" type="text/css" rel="stylesheet" media="screen">

I would appreciate another set of eyes to help spot what I may have overlooked. Several other channel forms are working correctly on the site.

  • Date picker doesn't display on Chrome/OSX for me, nor Firefox. Did you have a look at your browser console? Mine says "Uncaught TypeError: undefined is not a function", pointing at line 41 of your page's output. Firefox's browser console says "TypeError: jQuery(...).fancybox is not a function". Looks like there's a js problem with your script. – Solspace Aug 18 '14 at 7:51
  • I also get a Javascript error, but it says that this is not a function: $('select[name=type]').live('change', function() and references calendar_publish.js. It does not refer to fancybox.js – forrest Aug 19 '14 at 15:25
  • Start with this example code from the docs on a completely blank template: solspace.com/docs/calendar/channel_form Confirm that this basic form works (this means Calendar in a Channel Form works). Then work your way up to your final template code. Likely you have scripts loaded more than once, or some scripts that are not coded correctly. – Solspace Aug 20 '14 at 0:16
1

To get this working correctly I had to step back with version of jQuery I was running on that page. The calendar module comes with jQuery 1.3 referenced. I was able to get as high as jQuery 1.7.1 and have it work correctly, but if I went to the current release of 1.11.1, the calendar date selector does not work.

With regards to the calendar not working in Firefox, it was a permissions issue. I used logmein and set the group correctly and it appears fine.

| improve this answer | |
1

I was able to get this working by updating all instance of the live() jQuery function in calendar_publish.js to use on() instead. The syntax is a little different, so here is what I changed:


Line 1913, FROM:

$('select[name=type]').live('change', function()

TO

$(document).on('change', 'select[name=type]', function()

Line 1948, FROM:

$('div.all_day input:checkbox').live('change', function()

TO

$(document).on('change', 'div.all_day input:checkbox', function()

Line 1984, FROM:

$('.selector .item a', $cal_fields).live('click', function()

TO

$cal_fields.on('click', '.selector .item a', function()

Line 2046, FROM:

$('.rule_close', $cal_fields).live('click', function(){

TO

$($cal_fields).on('click', '.rule_close', function(){

That seemed to do it! Oh, btw, this is Solspace Calendar 1.8.14

| improve this answer | |
  • 1
    Much better approach than falling back to a 5 year old version of jQuery for the sake of one plugin. Thanks. – JamesNZ Dec 13 '15 at 2:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.