Active
Project:
Entity reference trim
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
9 Apr 2014 at 11:08 UTC
Updated:
25 Jul 2015 at 05:03 UTC
Jump to comment: Most recent
If the form which the entityreference is in contains an error (for example a required field is not filled) and you select a value in the entityreference, then the value is NOT trimmed. It seems as if the alter hook is not called at all in this case?
Any ideas for the reason?
Comments
Comment #1
anybodySet this problem to critical, because it's not possible to correctly submit the form anymore, because the whole text including "(X)" is filled into the hidden field.
Comment #2
2phaHmm, I have this problem too.
I ended up a small bit of js to get this functionality instead of using this module. https://2pha.com/blog/removing-entity-id-drupal-entity-reference-fields