Joomla Error – “JFolder::create: Could not create directory” while installing extension

Problem: I recently got the following error while trying to install a custom extension on Joomla. JFolder::create: Could not create directory Solution: This kind of error is generally related with folder permission. I checked for the folder permission in my Joomla installation and it seems to be fine. The folders have 755 permission. The other … Read more

Magento 2: Get All Product Attributes with Name and Value

This article shows how to load product by it’s ID and then get all attributes associated with that product in Magento 2. We print the attribute code, attribute name, and attribute value of all the attributes related to any particular product. We will be using Magento 2’s Service Layer for this task. Use of Service … Read more

Magento 2: Get Product Stock Quantity and Other Stock Information

This article shows how to get stock quantity (qty) of a product in Magento 2. We can also fetch other stock information like minimum quantity (min_qty), minimum sale quantity (min_sale_qty), maximum sale quantity (max_sale_qty), see if a product is in stock (is_in_stock), etc. We will be using Magento 2’s Service Layer for this task. Use … Read more

Magento 2: Load Product by ID and SKU

This article shows how to load product by id and sku in Magento 2. We will be using Magento 2’s Service Layer for this task. Use of Service Layer is highly encouraged by Magento. Below is a block class of my custom module (Chapagain_HelloWorld). I have injected object of \Magento\Catalog\Model\ProductRepository class in the constructor of … Read more

Magento 2: Get list of all Categories & Store Categories

This article shows how we can get list of all categories and all category of current store in Magento 2. Below is a block class of my custom module (Chapagain_HelloWorld). I have injected object of \Magento\Catalog\Model\ResourceModel\Category\CollectionFactory and \Magento\Catalog\Helper\Category classes in the constructor of my module’s block class. app/code/Chapagain/HelloWorld/Block/HelloWorld.php <?php namespace Chapagain\HelloWorld\Block; class HelloWorld extends \Magento\Framework\View\Element\Template … Read more

CodeIgniter: Simple Add, Edit, Delete, View – MVC CRUD Application

This article shows how to create a simple CRUD (Create, Read, Update, Delete) application with CodeIgniter. CodeIgniter (CI) is a PHP framework that helps building a full-fledged web application. This article is a continuation of the basic tutorial present in the official CodeIgniter site. The tutorial had view and add data part. But, it didn’t … Read more