DEPRECATION WARNING
This documentation is not using the current rendering mechanism and is probably outdated. The extension maintainer should switch to the new system. Details on how to use the rendering mechanism can be found here.
Lookup¶
Imagine somebody filling out a SQL Frontend form where one field is a username. Based on the username another field should get prefilled with an email address. Thus, based on the username entered, you could (live) lookup (hence the name) the email address.
sDatabase¶
String. If the database differs from dbal/sDatabase, enter it here.
aWhere¶
Array with where parts to identify the new entry. Use markers here:
aWhere = array(
'username:###username###',
'deleted:0',
'disable:0'
)
sField¶
String. The usual Action-needed (action has to be getFormValidation) field that determines the other one. In our example:
username
sNotFound¶
String that is used if there is nothing found. If not defined and nothing is found, nothing is changed within the field. Keep in mind that if you specify sNotFound the plugin overrides the second field (i.e., email) no matter what (sNotFound overwrites previously inserted text).
bOnlyUseIfSingleEntryFound¶
Boolean. If set to true, only if one entry matches, that one is used. This means, that if you entered "max" and the database contains three entries with max (max1, max2, max_is_great), nothing is done.