I uploaded additional files for products. They get stored in media folder in Magento root directory. How can I access files stored at media folder in Magento root folder? Should I use a method for accessing files outside Root directory or simply involve a direct access code in php?
It depends from where you want to call that access from; there's 2 possibilities:
from within the Magento Administration - say, a CMS page or a Block. There, you can refer to the 'media' directory via
from a template-file (phtml)
refer to the skin directory:
<img src="<?php echo $this->getSkinUrl('images/filename.jpg')?>"
refer to the media directory:
<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA); ?>
There's also plenty of sources: