Chris2656882
Posts: 0
Joined: Fri May 11, 2012 3:47 pm

Element reference before page load

If one refers to a component name in a javascript file that loads before the page is shown (either in a project javascript file or in Device Ready or Load page event), all javascript on the page will fail.

In traditional JQuery, the action would be ignored, but in Tiggzi, the page fails.

I noticed that it only occurs when you refer to an element using the Tiggr shorthand. If one refers to the variable in proper JQuery notation, the script will continue to work.

• Tiggr('field').html('some data');//entire script fails

• $('input[dsid="field"]').html('some data');//script continues to work

maxkatz
Posts: 0
Joined: Fri Aug 13, 2010 3:24 pm

Element reference before page load

We'll test and fix this as soon as possible...

maxkatz
Posts: 0
Joined: Fri Aug 13, 2010 3:24 pm

Element reference before page load

Here is a workaround you can use for now:

code
Tiggzi('field') && Tiggzi('field').html('some data');
/code

Chris2656882
Posts: 0
Joined: Fri May 11, 2012 3:47 pm

Element reference before page load

Is there a fundamental difference between Tiggzi('field') and Tiggr('field')? Should I use one over the other?

maxkatz
Posts: 0
Joined: Fri Aug 13, 2010 3:24 pm

Element reference before page load

Same, Tiggzi(..) has the new name. We will also update Tiggzi to work with the problem you posted here.

maxkatz
Posts: 0
Joined: Fri Aug 13, 2010 3:24 pm

Element reference before page load

Should be fixed.

Return to “Issues”