Before saying this post is a duplicate please read.
I have a real head scratcher for you. I am trying to get the current package name being used. In a clean install with 1.9, the current package name is
rwd. However, all methods that I have tried return the value
default. I find this very odd and wonder if anyone else has faced this problem?
I have tried the following: (please note that I have looked through as many exchange posts that I could find relating to getting this info with no luck. https://stackoverflow.com/questions/11155570/how-to-get-current-theme-name-in-magento
Mage::getSingleton('core/design_package')->getPackageName() Mage::getDesign()->getPackageName() Mage::getDesign()->getPackageName('frontend') Mage::getDesign()->getTheme('frontend')
Mage::getDesign()->getDefaultTheme() Mage::getStoreConfig('design/package/name'); Mage::app()->getStore()->getStoreId(); Mage::getStoreConfig('design/package/name', $storeId);
All of these methods return
default which is not correct. I noticed that during a fresh 1.9 install the default package name is
design/package/name does not exist in
core_config_data table unless you save the configurations in the backend.
So, why does Magento return
default even if the path does not yet exist in the table? Also, when it does exist and contains
rwd as the package name, why does it still return
Update: I should mention that I am trying to retrieve this info from the backend. It appears it will pull the right info if you are trying to retrieve it from the frontend only.