element php validation not called

jaga

New Member
Hello,

Recently I have updated joomla to the latest version (as the warning on the forum regarding the compatibility was removed) and took the fabrik from github (joomla3 branch) following all steps in the document describing the github update procedure.
I have now a major issue with the elements php validation. It seems that the code is not called at all anymore for the new/changed php validations. The validations that were not modified are still, working, but as soon as these are changed, they stop working.
Using Firebug I was able to see errors like:

Fabrik form::addElementFX: Not an element or group: f
fabrik-min.js (line 1)

ReferenceError: invalid assignment left-hand side


...et('value') = 't') { Fabrik.blocks['form_1_32'].doElementFX('fabrik_trigger_f', ...
which seems to be related to a call to element-min.js:
if (this.get('value') = 't') {Fabrik.blocks['form_1_32'].doElementFX('fabrik_trigger_f', 'h', this)}
The odd fact is that the validations which were already defined and not updated are still working, getting bad in the moment when are updated. The new php validations are not working from the beginning.
Any action that you can recommend to fix this?
Regards,
Jaga.
 
Hello 'troester',

Thank you for your message and sorry for my late reply (I've got the chance to take one week of vacation and I've been completely disconnected during that time).

I ave clean everything, starting with the Joomla cache and ending with the browsers (because I have used different browsers on different machines). None of those actions helped. As I said before, the browser debuggers didn't reveal anything (I had enabled the Joomla & fabrik debugging). Any direction of investigation will be truly appreciated.

Thanks again,
Jaga.
 
I can't replicate. Php validation is running as expected on my site (with/without ajax validation, with/without multiple validations on one element).

Can you check if the GitHub update was correct ("validations which were already defined and not updated are still working, getting bad in the moment when are updated" sounds a bit like the Fabrik/J!3.3 issue).
 
Hello troester,
Thank you for your help and directions. I don't know how deep are you in the fabrik development/troubleshooting.
The fresh J!3.3 + Fabrik (GitHub) the validations are working fine. The system where the problems are shown is one developed with J!3.2 and Fabrik 3.1 and updated step by step with the newest versions of Joomla and Fabrik.
I have tested a 'not empty' validation on my system and I found that the fabrik element into the database is changing as follow:
When the validation was working the params field of the element in the database was:
"notempty-message":["Details"],
"notempty-validation_condition":[""],
"tip_text":[""],
"validations":{"plugin":["notempty"],
"plugin_published":["1"],
"validate_in":["both"],
"validation_on":["both"],
"show_icon":["1"]}}

after the element was saved in back-end (no modification, but just open and click save), the validation was not working anymore and the params field changed as below (note that the square brackets are missing):
"notempty-message":"Details",
"notempty-validation_condition":"",
"tip_text":"",
"validations":{"plugin":"notempty",
"plugin_published":"1",
"validate_in":"both",
"validation_on":"both",
"show_icon":"1"}}

What am I missing here? Any direction that you can give me will be highly appreciated.

Thanks and best regards,
Jaga
 
Double-check if your GitHub update has run correctly.

administrator/components/com_fabrik/classes/33/field.php
must have at line 555ff
// Allow for repeatable elements
$repeat = (string) $element['repeat'];
$this->repeat = ($repeat == 'true' || $repeat == 'multiple' || (!empty($this->form->repeat) && $this->form->repeat == 1));
 
Hello troester,

You're my todays hero! The GitHub update was not good as the entire folder 33 was missing. This was leading to the issues that I had. I have spent few days because of this and probably many more without your help.
Thanks again and all the best,
Jaga.
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top