I try to construct a field and I wonder how should I implement this process via Field API:
- User enter some data to the field. Let's say, the data entered is a node title.
- User hits the "Save" button, but what is actually saved in the database is the node ID of the node whose title has been entered by the user.
Something like this happens with the Entity Reference module: I enter the title of the entity (as I 'm getting assistance through autocomplete), but the module saves target_id
, not the title I have actually entered.
How can I gain such behavior?