Admin Form Field Types
Updated . Posted . Visible to the public.
The various types are:
- text
- textarea
- multiline
- select
- multiselect
- radio
- checkbox
- password
- time
- note
- label
- link
- image
- file
- date
- submit
See the link for detailed usage information
Last edit
Related cards:
Add comment to form input in admin
$afterElementHtml = '<p class="nm"><small>' . ' this is the hint! ' . '</small></p>';
$linkFieldset->addField('field_name', 'text', array(
'after_element_html' => $afterElementHtml,
));

Frontend With Route:
<config>
<frontend>
<routers>
<namespace_module>
<use>standard</use>
<args>
<module>Namespace_Module</module>
...
Custom Cache Type Definition
Adding this XML will cause an additional entry to appear in the Magento Cache Management screen.
<global>
<cache>
<types>
<your_cache_type module="your_module" translate="label description">
...
Config Event Observer Definition (Frontend, Admin & Global)
Frontend:
<config>
<frontend>
<events>
<the_name_of_the_event_to_observe>
<observers>
<namespace_module>
<class>namespace_module/obser...
Config Layout Definition (Frontend & Admin)
Frontend:
<config>
<frontend>
<layout>
<updates>
<namespace_module>
<file>namespace-module.xml</file>
</namespace_module>
</up...
Changing The Admin Theme
Put this in your local.xml
:
<config>
<stores>
<admin>
<design>
<theme>
<default>yourtheme</default>
</theme>
</design>
...
Add A Tab To The Admin Product Screen
Adding A Tab To The Product Screen
-
Declare an admin layout XML file for your module in your config.xml:
...
Add A Tab To The Admin Product Screen
Declare an admin layout XML file for your module in your config.xml
:
<config>
<adminhtml>
<layout>
<updates>
<your_module>
<file>your-module.xml</file>
...
Posted by Mike Whitby to Magento (2012-11-28 10:31)