Is there anything wrong with getting data directly from Block, and not from Model or resource? If yes, what are the threats? I mean, like this:
$block = Mage::app()->getLayout()
->getBlockSingleton('adminhtml/catalog_product_attribute_edit_tab_options');
$label = $block->getLabelValues();
Many thanks!!
1 Answer 1
Still working and have doubts on my answer.
Like I said before in the comments, you could also implement the underlaying functionality in your code. It is just a useful way of not having to copy/paste good code to another location.
In this case, the block has a lot of easy to use features to work with attribute options.
You could also try to understand the underlaying code in the block and implement it accordingly.
More than happy to help you out.
-
Cool, Mr Jeroen! Thanks! You have explained it quite well! Have you seen my new question?Supersonic– Supersonic2015年03月25日 21:31:05 +00:00Commented Mar 25, 2015 at 21:31
-