Read Magento 2 Basics Part 1

Get your Ecommerce flexibility using Magento 2

Magento 2 is the newest member of the Magento family, an open-source platform to accelerate your ecommerce goals. It has new and improved features that helps to increase user interaction and perform all business functions smoothly.

It basically integrates object-oriented programming with Relational DataBase Management System, while providing a Zend Framework in the background.

Just follow some simple steps described below to create category, products, and customers on your magento admin.

Programmatically Create Category, Products and Customer in Magento 2

With Magento 2 you can organise and administer your business data. Moreover its scalability feature allows you to make changes effortlessly.

Follow these simple steps given below to create category, products and customers.

Step 1: First Create the scripts/abstract.php file in magento root directory. Place the following code in the file.

Step 2: For Create category

Follow these subsequent steps

Step 2.1: Create scripts/createCategory.php file in magento root directory and place the code below to get category data.

Step 2.2: Run the command http://www.yourdomian.com/scripts/createCategory.php in your browser. This will create category.

Step 3: For Create Product (simple)

Follow these subsequent steps to create product (simple)

Step 3.1: Create scripts/createProduct.php file in magento root directory and place the code shown below in that file.

Step 3.2: Run command http://www.yourdomian.com/scripts/createProduct.php in your browser. This will create simple product with image and custom options.

Step 4: For Create Customer

Follow these subsequent steps to create customer

Step 4.1: Create scripts/createCustomer.php file in magento root directory and put below code to  get all the Customer data.

Step 4.2: Run http://www.yourdomian.com/scripts/createCustomer.php  command in your browser. This will create customer in magento.

Hope this will help you!

Thank you.

Gordhan Chauhan

Gordhan Chauhan | Sr. Magento Developer

I work as Sr. Magento Developer in Yudiz Solutions Pvt. Ltd. -
a leading mobile apps, mobile games and web development company. I write blogs to share my knowledge and ideas to my audience. I am passionate about exploring and develop new stuff in magento and web development.
mm

Gordhan Chauhan Sr. Magento Developer

I work as Sr. Magento Developer in Yudiz Solutions Pvt. Ltd. - a leading mobile apps, mobile games and web development company. I write blogs to share my knowledge and ideas to my audience. I am passionate about exploring and develop new stuff in magento and web development.

Comments are closed.

Top