Zend Anwar

Full stack web developer

Category: Magento 2

Magento 2 No options under configuration>general>design

I was bit confuse about design option missing. I found in Content > Configuration . Please change header & footer option from here.

Read More

Fatal error: Class Zend\Stdlib\Parameters contains …. in Magento 2

To solve this problem run following commands: 1. php bin/Magento setup:upgrade 2. php bin/Magento setup:static-content:deploy 3. php bin/Magento cache:clean 4. php bin/Magento cache:flush If still exist your problem, please restart your web server. I hope solve this issue.

Read More

Fatal error: Allowed memory size of 792723456 bytes exhausted in Magento 2

Please follow below step with CLI php bin/magento setup:upgrade php bin/magento setup:static-content:deploy php bin/magento cache:flush php bin/magento cache:clean If you face same issue please change memory configuration [root-folder]/.user.ini memory_limit = 768M [root-folder]/.htaccess (two place) php_value memory_limit 768M [root-folder]/pub/.user.ini memory_limit = 768M [root-folder]/pub/.htaccess (two place) php_value memory_limit 768M

Read More

How to transfer localhost to server in Magento 2

Please follow below step Copy source files and database Update config file with new database location in app/etc/env.php Go to database and change host in core_config_data table to new domain/IP After complete above procedure and then clear cache with following command php bin/magento indexer:reindex php bin/magento cache:flush

Read More

Magento 2 add to cart not working localhost Only in chrome

Change base url http://localhost/ to http://127.0.0.1 please follow below step: Go to database  and find “core_config_data” table Then change secure and unsecure base url

Read More

Zendanwar_HelloWorld db schema version: defined in codebase – 0.0.1, currently installed – 1.0.0

mysql> SELECT * FROM setup_module WHERE module = ‘Zendanwar_HelloWorld ‘; +———————–+———————-+———————+ | module | schema_version | data_version | +———————–+———————-+———————+ | Magento_Directory | 1.0.0 | 1.0.0 | +———————–+———————-+———————+ Just edit schema_version & data_version with 0.0.1

Read More

How to check modules status in Magento 2

Just follow the below CLI command php bin/magento module:status You can also check from following file. app/etc/config.php

Read More

Magento 2 Run Code From An External File/Script

To access the Magento 2 core functionality, we need to include the below code in the top of the external file use Magento\Framework\App\Bootstrap; require __DIR__ . ‘/app/bootstrap.php’; $params = $_SERVER; $bootstrap = Bootstrap::create(BP, $params); Example file path: C:/xampp/htdocs/magento2/script.php <?php use Magento\Framework\App\Bootstrap; require __DIR__ . ‘/app/bootstrap.php’; $params = $_SERVER; $bootstrap = Bootstrap::create(BP, $params); $obj = $bootstrap->getObjectManager(); […]

Read More

How to enable error in Magento 2

Go to your Magento2 root directory Then, go inside folder pub/errors There, you will see a file named local.xml.sample Rename it to local.xml, i.e. remove the “.sample” from the name of that file. Refresh Cache from your Magento Admin (System -> Tools -> Cache Management).

Read More

Magento 2 reindex all in command line

To get list of indexer in Magento 2 php bin/magento indexer:info Indexer status check in Magento 2 php bin/magento indexer:status Only one indexer please follow following command: php bin/magento indexer:reindex indexer_name php bin/magento indexer:status catalog_category_product Magento 2 reindex all with following command php bin/magento indexer:reindex If fill memory limit, try with following command php bin/magento […]

Read More