December 9, 2014 in Feedback
The core/global/forms/text.phtml template and \IPS\Helpers\Form\Text should be amended to allow custom keys for the autocomplete datalist. I can think of many instances in which one would want to use the option text for presentational purposes; for instance, searching through nodes by name but saving the ID in the database.
A simple way to accomplish it would be to add another variable to the helper's autocomplete options named something akin to keysAsValues and then an if clause in text.phtml which checks for it and outputs both $k and $v rather than just the latter.
Either that, or there's a better way of using separate keys and values which I haven't come across yet.
This topic is now archived and is closed to further replies.
Started February 26
Started March 13, 2023
Started 28 minutes ago