Reputation: 2478
I'm trying to use helpers from actions in this way:
sfContext::getInstance()->getConfiguration()->loadHelpers(array('I18N', 'Asset', 'Url'));
echo image_tag('bullet_red.png');
echo link_to('Ver detalles', 'ver-detalles/' . $record->getIdregistros(), 'class="btn btn-success btn-mini"');
But I get this error:
Fatal error: Call to undefined function _parse_attributes() in /var/www/html/monitor/lib/vendor/symfony/lib/helper/AssetHelper.php on line 333
Why?
Upvotes: 1
Views: 1655
Reputation: 5986
_parse_attributes() function is located in the Tag Helper.
so you will have to import the Tag Helper as well
sfContext::getInstance()->getConfiguration()->loadHelpers(array('I18N', 'Asset', 'Url', 'Tag'));
Upvotes: 6