Magento admin yes no in system.xml
You can add yes/ no dropdown in magento admin by adding simply the following code in system.xml file:
<fields> <yourtagname translate="label tooltip comment"> <label> - Select - </label> <frontend_type>select</frontend_type> <source_model>adminhtml/system_config_source_yesno</source_model> <sort_order>1</sort_order> <show_in_default>1</show_in_default> <show_in_website>1</show_in_website> <show_in_store>1</show_in_store> <comment>Your comment.</comment> </yourtagname> </fields>
Which will generate the select box like this –
Advertisements