Development

#1385 (observe_field with frequency=>0 outputs incorrect javascript)

You must first sign up to be able to contribute.

Ticket #1385 (closed defect: fixed)

Opened 1 year ago

Last modified 1 year ago

observe_field with frequency=>0 outputs incorrect javascript

Reported by: Michael.Nolan Assigned to:
Priority: minor Milestone: 1.0.0
Component: Version: 1.0.0-rc1
Keywords: Cc:
Qualification:

Description

If you output an observe_field:

<?php echo observe_field('module', array('url'=>url_for('quicklink/updateActionSelect'), 'frequency'=>0, 'update'=>'action', )); ?>

to monitor a field it produces the following javascript:

<script type="text/javascript">
//<![CDATA[
new Form.Element.EventObserver("module", 0, function(element, value) {new Ajax.Updater('action', '/quicklink/updateActionSelect', {asynchronous:true, evalScripts:false, parameters:value})});
//]]>

</script>

For Form.Element.EventObserver?() the zero after "module" shouldn't be there. Removing the 'frequency'=>0 corrects the fault but it should be able to handle this gracefully to allow for computed frequency updates.

Change History

02/18/07 10:52:59 changed by fabien

  • status changed from new to closed.
  • resolution set to fixed.

(In [3497]) fixed observe_field with frequency=>0 outputs incorrect javascript (closes #1385)

02/18/07 10:53:10 changed by fabien

  • milestone set to 1.0.0.