In Magento i’ve got a tab with a form in the Backend System > Configuration section with 2 input fields.
I’d like to manipulate the data from those two fields before their saved. Is that possible?
And if so, whats the cleanest way to do that.
Many thanks
These types of jobs are the purpose of “backend models”. If a field has a backend_model configured, that backend model’s
_beforeSave()method will be invoked prior to the value being entered into the database.See
Mage/Paygate/etc/system.xml& search for<backend_model>See
Mage_Adminhtml_Model_System_Config_Backend_Encrypted::_beforeSave()