search
top

Delete Directory in PHP

This post will be helpful to those who work with directories and files. I am writing here the PHP code for deleting the directory. <?php $extract_dir = 'path'; //physical path of the directory if(deleteDirectory($extract_dir)) //delete directory { $msg = "$extract_dir was deleted"; echo $msg."<br/>"; } else { $msg = "$extract_dir was not deleted"; echo...
read more

Magento Essentials

I am listing below important variable used in Magento. <?php echo Mage::app()->getFrontController()->getRequest()->getHttpHost(); //displays host name echo Mage::getBaseDir(); //gives physical path of the sites root directory echo $this->getSkinURL(); //gives relative path of the sites default skin folder echo Mage::getBaseURL(); //gives relative path of the site echo...
read more

top