Issues

ZF-5808: dojo()->onLoadCaptureStart() appears on page before dijit elements are loaded

Issue Type: Bug Created: 2009-02-16T22:18:06.000+0000 Last Updated: 2009-02-25T10:00:36.000+0000 Status: Resolved Fix version(s): - 1.7.6 (02/Mar/09)

Reporter: Amjad Mohamed (andho) Assignee: Matthew Weier O'Phinney (matthew) Tags: - Zend_Dojo

Related issues: - ZF-4587

Attachments:

Description

dojo()->onLoadCaptureStart() appears on page before dijit elements are loaded

<pre class="highlight">
10 dojo.addOnLoad(function() {
11 from = dojo.byId('calldetails-from');
12 frombutton = dijit.byId('frombutton');
13 serviceprovider = dojo.byId('calldetails-service_provider');
14 spbutton = dijit.byId('service_providerbutton');
15 contact_name = dijit.byId('calldetails-contact_name');
16 contact_no = dijit.byId('calldetails-contact_no');
17 callerinfo = dojo.byId('callerinfo');
18 historydiv = dojo.byId('history');
19 submit = dijit.byId('Submit');
20
21 dojo.connect(from, 'onblur', checkExists);
22 dojo.connect(frombutton, 'onClick', loadHistory);
23 dojo.connect(serviceprovider, 'onblur', getHistory);
24 dojo.connect(spbutton, 'onClick', loadHistorySP);
25 }
26 );
27 dojo.addOnLoad(function() {
28 spstore = new dojo.data.ItemFileReadStore({"url":"action\/get-service-providers"});
29 });
30 dojo.addOnLoad(function() {
31 dojo.forEach(zendDijits, function(info) {
32 var n = dojo.byId(info.id);
33 if (null != n) {
34 dojo.attr(n, dojo.mixin({ id: info.id }, info.params));
35 }
36 });
37 dojo.parser.parse();
38 });

if you look at this code the Zenddijits are being processed last. So any code inside dojo()->onLoadCaptureStart() which uses dijit.byId('element-id') will return null or undefined

Comments

Posted by Matthew Weier O'Phinney (matthew) on 2009-02-17T04:01:21.000+0000

This is a duplicate of ZF-4587, and will be resolved for 1.8 or sooner.

Posted by Matthew Weier O'Phinney (matthew) on 2009-02-25T10:00:36.000+0000

Fix committed to trunk and merged to 1.7 release branch; should release with 1.7.6 next week.

Have you found an issue?

See the Overview section for more details.

Copyright

© 2006-2016 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.

Contacts