Cannot add element in Console

jmoises

Active Member
After the creation of a custom template that i show only couple elements, i notices on my browser console a lot of text like this:

Fabrik form::addElements: Cannot add element "my_element1" because it does not exist in HTML. utils.js:3
Fabrik form::addElements: Cannot add element "my_element1_ro" because it does not exist in HTML. utils.js:3

should i be worried? how can i avoid this ?

thanks for any advise
 
i follow @cheesegrits recomendation and i still get the message,

Ah, OK, well if it's a custom template, and you aren't running the usual template code that outputs the element structure, then it's almost certainly because you aren't rendering the elements with the right "wrappers". Take a look at how an element is rendered in details view by the standard template. All elements will have a wrapper, usually a div, with that 'tablename___elementname_ro' ID. Our JS needs that ID so it can find the element in the DOM.

-- hugh

i found another post

https://fabrikar.com/forums/index.php?threads/fabrik-form-addelements-cannot-add-element.40572/

and @cheesegrits say this

You can ignore that, it's basically just debug output, and is expected for elements which aren't part of the DOM structure.

-- hugh

But i really need to hide this, it show a lot of elements and i concert about the security, user are found out about all the elements names / fields of database.

thanks for any other reply
 
You can comment lines for this direcly in /media/com_fabrik/js/form.js.
Search for string 'fconsole('Fabrik form::addElements: Cannot add element'.
Remember: Your Fabrik global settings need set Allow Fabrik debug -> yes.
This force loading uncompressed form.js file from folder js instead from folder dist.
Need to do that always after Fabrik update.
 
You can comment lines for this direcly in /media/com_fabrik/js/form.js.
Search for string 'fconsole('Fabrik form::addElements: Cannot add element'.
Remember: Your Fabrik global settings need set Allow Fabrik debug -> yes.
This force loading uncompressed form.js file from folder js instead from folder dist.
Need to do that always after Fabrik update.

ok great thanks for this i am trying!
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top