I'm searching for a solution with the magento buildin way to create html select blocks, with aria-required. I can display basic attributes like the id or the class for example, but not this attribute.
Here is my first essay:
$select = Mage::app()->getLayout()->createBlock('core/html_select');
$select->setName($name)
->setClass($class)
->setId($id);
->setArialRequired($ariaRequired); //doesn't work
Here is my second essay:
$select = Mage::app()->getLayout()->createBlock('core/html_select');
$select->setData(array(
'name' => $name,
'class' => $class,
'id' => $id,
'aria-required' => $ariaRequired //doesn't work
));