Tag Archives: Magento

Password Protect Directories Using Htpasswd On Nginx

Nginx 1.4.3, Magento CE 1.7.0.2 Apache offers us a neat security feature using http auth. It provides a simple way of protecting files and directories which is extremely useful, albeit not high-level security. Nginx users will be happy to hear that this functionality is also available by default on Nginx 1.4.3 using the HttpAuthBasicModule. The […]

Magento Get Category List As Admin Select

Magento CE 1.8.0.0 Sometimes we want to retrieve a list of all categories on site to populate a select input field in admin. Here’s one way this can be achieved. I’m assuming we have a custom module called My_Module in the community folder. File: app/code/community/My/Module/Helper/Data.php 12345678910111213141516171819202122232425262728… public function getAllCategoriesArray($optionList = false) {     $categoriesArray […]