Forums

Not able to edit form field properties

zdmdesignz 15 Dec, 2009
Recently, my chronoforms began acting strange. While I was editing a form, I would get errors at the top of the page I was on (a gigantic block of code). Now when I edit a form in wizard mode, The properties box does not drop down at all for any of my form fields. I cannot edit any fields anymore. Here is the code that displays at the top:


dow.addEvent('domready', function() { var top = $('right_column').getPosition().y - 2; var marginChange = new Fx.Style('right_column', 'margin-top', {wait:false, duration:500, transition:Fx.Transitions.Elastic.easeOut});	 window.addEvent('scroll', function() { if(($('left_column').getCoordinates().height + $('top_column').getCoordinates().height) > ($('right_column').getCoordinates().height + window.getScrollTop() - top - 50) ){ marginChange.start(Math.max(0, window.getScrollTop() - top)); } }); var top2 = $('right_column2').getPosition().y - 2; var marginChange2 = new Fx.Style('right_column2', 'margin-top', {wait:false, duration:500, transition:Fx.Transitions.Elastic.easeOut});	 window.addEvent('scroll', function() { if($('emailbuilder').getStyle('display') == 'block'){ if(($('top_column2').getPosition().y - window.getScrollTop()) <= 0){ marginChange2.start(Math.max(0, window.getScrollTop() - $('top_column2').getPosition().y)); } } }); }); window.addEvent('domready', function() { $ES('.form_item',$('left_column')).each(function(theitem){ theitem.addEvents({ 'mouseover': function(e) { //new Event(e).stop(); theitem.effect('background-color', {wait: false, duration: 100}).start('E7DFE7','E7DFE7');	 }, 'mouseout': function(e) { //new Event(e).stop(); theitem.effect('background-color', {wait: false, duration: 100}).start('ffffff','ffffff'); }, 'click': function(e) { //new Event(e).stop(); $ES('.form_item',$('left_column')).each(function(item2){ item2.setStyle('border', '0px solid #000'); $E('.delete_icon', item2).setStyle('display', 'none'); }); $$('div.Propertiesitem').each(function(item){ item.setStyle('display','none'); }); theitem.effect('background-color', {wait: false, duration: 100}).start('ffffff','ffffff'); theitem.setStyle('border', '1px solid #000');	 $E('.delete_icon', theitem).setStyle('display', 'inline'); this.showProperties(this.getTag());	 $('formbuilder').setStyle('height', ( ($('left_column').getCoordinates().height + $('top_column').getCoordinates().height) > $('right_column').getCoordinates().height ) ? ($('left_column').getCoordinates().height + $('top_column').getCoordinates().height + 150) : $('right_column').getCoordinates().height + 150); }	 }); $E('.delete_icon', theitem).addEvent('click', function(e) { new Event(e).stop(); this.getParent().remove(); $$('div.Propertiesitem').each(function(item){ item.setStyle('display','none'); }); }); $E('.config_icon', theitem).addEvent('click', function(e) { new Event(e).stop(); $ES('.form_item',$('left_column')).each(function(item2){ item2.setStyle('border', '0px solid #000'); $E('.delete_icon', item2).setStyle('display', 'none'); }); $$('div.Propertiesitem').each(function(item){ item.setStyle('display','none'); }); theitem.effect('background-color', {wait: false, duration: 100}).start('ffffff','ffffff'); theitem.setStyle('border', '1px solid #000');	 $E('.delete_icon', theitem).setStyle('display', 'inline'); theitem.showProperties(theitem.getTag());	 $('formbuilder').setStyle('height', ( ($('left_column').getCoordinates().height + $('top_column').getCoordinates().height) > $('right_column').getCoordinates().height ) ? ($('left_column').getCoordinates().height + $('top_column').getCoordinates().height) : $('right_column').getCoordinates().height ); }); theitem.setProperty('title', 'form_item'+counter); if($chk($E('a.tooltiplink', theitem))){ var Tips1 = new ChronoTips($E('a.tooltiplink', theitem), $E('div.tooltipdiv', theitem).getText(), {elementid:theitem.getProperty('title')}); } //new Element('input', {'name':'slabel[]', 'type':'hidden', 'id':'slabel_'+theitem.getProperty('title'), 'value':''}).injectAfter($('uploadfields')); counter = counter + 1; }); new Sortables($('left_column'), { handles: 'span.drag'	 }); //emails emailcounter = 1; tinyMCE.execCommand('mceAddControl', false, 'editor_email_'+0); $$('.cf_email').each(function(emailitem){ if(($chk($E('input[name^=to_]', emailitem)) || $chk($E('input[name^=dto_]', emailitem))) && ($chk($E('input[name^=subject_]', emailitem)) || $chk($E('input[name^=dsubject_]', emailitem))) && ($chk($E('input[name^=fromname_]', emailitem)) || $chk($E('input[name^=dfromname_]', emailitem))) && ($chk($E('input[name^=fromemail_]', emailitem)) || $chk($E('input[name^=dfromemail_]', emailitem))) ){ emailitem.effect('background-color', {wait: false, duration: 100}).start('CEFF63','CEFF63'); } emailitem.addEvent('click', function() { $$('div.cf_email').each(function(item){ item.setProperty('id',''); item.setStyles({'border':'1px #111 solid'}); }); this.setProperty('id','cf_email_active'); this.setStyles({'border':'3px #111 solid'}); ShowEmailProperties(); }); }); $$('.form_item_email').each(function(formitem){ formitem.addEvent('click', function() { $$('.form_item_email').each(function(item2){ item2.setStyle('border', '0px solid #000'); $E('.delete_icon_email', item2).setStyle('display', 'none'); }); this.setStyle('border', '0px solid #000'); $E('.delete_icon_email', this).setStyle('display', 'none'); this.effect('background-color', {wait: false, duration: 100}).start('ffffff','ffffff'); this.setStyle('border', '1px solid #000');	 $E('.delete_icon_email', this).setStyle('display', 'inline'); }); }); $$('.delete_icon_email').each(function(deleteicon){ deleteicon.addEvent('click', function(e) { //new Event(e).stop(); droparea = this.getParent().getParent(); this.getParent().remove(); if(($chk($E('input[name^=to_]', droparea)) || $chk($E('input[name^=dto_]', droparea))) && ($chk($E('input[name^=subject_]', droparea)) || $chk($E('input[name^=dsubject_]', droparea))) && ($chk($E('input[name^=fromname_]', droparea)) || $chk($E('input[name^=dfromname_]', droparea))) && ($chk($E('input[name^=fromemail_]', droparea)) || $chk($E('input[name^=dfromemail_]', droparea))) ){ droparea.effect('background-color', {wait: false, duration: 100}).start('CEFF63','CEFF63'); }else{ var email_params = $('params_'+droparea.getProperty('name')).value.split(','); $('params_'+droparea.getProperty('name')).value = email_params[0] + ',' + email_params[1] + ',' + '0'; $('prop_cf_Email_enable').value = 0; $('prop_cf_Email_enable').disabled = true; droparea.effect('background-color', {wait: false, duration: 100}).start('FFAEA5','FFAEA5'); } }); }); }); function switchstep(stepid){ if(stepid == '1'){ $('formbuilder').setStyle('display', 'block'); $('emailbuilder').setStyle('display', 'none'); $('templatebuilder').setStyle('display', 'none'); $('AfterFormSubmission').setStyle('display', 'none'); $('step1image').setProperty('src', 'components/com_chronocontact/images/steps/step11.png'); $('step2image').setProperty('src', 'components/com_chronocontact/images/steps/step22.png'); $('step3image').setProperty('src', 'components/com_chronocontact/images/steps/step32.png'); $('step4image').setProperty('src', 'components/com_chronocontact/images/steps/step42.png'); }else if(stepid == '2'){ $('formbuilder').setStyle('display', 'none'); $('emailbuilder').setStyle('display', 'block'); $('templatebuilder').setStyle('display', 'none'); $('AfterFormSubmission').setStyle('display', 'none'); $('step1image').setProperty('src', 'components/com_chronocontact/images/steps/step12.png'); $('step2image').setProperty('src', 'components/com_chronocontact/images/steps/step21.png'); $('step3image').setProperty('src', 'components/com_chronocontact/images/steps/step32.png'); $('step4image').setProperty('src', 'components/com_chronocontact/images/steps/step42.png'); }else if(stepid == '3'){ $('formbuilder').setStyle('display', 'none'); $('emailbuilder').setStyle('display', 'none'); $('templatebuilder').setStyle('display', 'block'); $('AfterFormSubmission').setStyle('display', 'none'); $('step1image').setProperty('src', 'components/com_chronocontact/images/steps/step12.png'); $('step2image').setProperty('src', 'components/com_chronocontact/images/steps/step22.png'); $('step3image').setProperty('src', 'components/com_chronocontact/images/steps/step31.png'); $('step4image').setProperty('src', 'components/com_chronocontact/images/steps/step42.png'); }else if(stepid == '4'){ $('formbuilder').setStyle('display', 'none'); $('emailbuilder').setStyle('display', 'none'); $('templatebuilder').setStyle('display', 'none'); $('AfterFormSubmission').setStyle('display', 'block'); $('step1image').setProperty('src', 'components/com_chronocontact/images/steps/step12.png'); $('step2image').setProperty('src', 'components/com_chronocontact/images/steps/step22.png'); $('step3image').setProperty('src', 'components/com_chronocontact/images/steps/step32.png'); $('step4image').setProperty('src', 'components/com_chronocontact/images/steps/step41.png'); }else{} }
GreyHead 15 Dec, 2009
Hi zdmdesignz,

What you are seeing is a chunk of the ChronoForms JavaScript. We've seen something like this a few times before. It seesm to occur when there is a JavaScript error on the Admin page. That can be from conflict with code from another extension or admin module, or an error inside the form code.

If you are using IE then switching browser may fix it, otherwise see if FireBug shows up an JavaScript errors on the page.

Bob
This topic is locked and no more replies can be posted.