Custom SMTP for Magento2 : An expansion presenting with best features for the consumers. The easily accessible and user friendly magento extension is on its way to make the work more convenient and affordable for the users. Custom SMTP is
How to use Registry Object in Magento 2.0
Magento 2.0 have a registry object that should help easy the transition for extensions. The class is Magento\Framework\Registry, and you can inject it in any constructo
1 2 3 4 5 6 7 8 9 |
public function __construct(//... \Magento\Framework\Registry $registry, //... ) { //... $this->registry = $registry; //... } |
and then set variables with
1 |
$this->registry->register('test_var', 'this is a test!'); |
and fetch those variables back (even from
How to run cron in Magento 2.0
Magento Recommends 3 type of cron are introduced in magento-2 as given below
1 2 3 |
*/1 * * * * php -c /path/to/magento2/bin/magento cron:run */1 * * * * php -c /path/to/magento2/bin/magento/update/cron.php */1 * * * * php -c /path/to/magento2/bin/magento setup:cron:run |
but we do not need to configure all of them , 1st cron command will work for reindexes indexers, send automated e-mails, generates the sitemap, and so
New Extension Installation step in Magento 2.0
1) Upload new module to app/ 2) bin/magento module:enable EmizenTech_NewModule 3) bin/magento setup:upgrade 4.1) DI configuration must be cleared
1 |
rm -rf var/di |
4.2) Compile
1 |
bin/magento setup:di:compile |
How to Change Admin url in Magento 2.0
To change the url open the file env.php in the path app/etc.
1 2 3 |
array ( 'frontName' => 'admin', // Default name which we was given at the time of installation. ), |
How to create admin user in Magento 2.0
You can use Magento2 CLI to create new admin user with the following command
1 |
<path_to_magento>/bin/magento admin:user:create [--admin-user="emizentech"] [--admin-password="emi@emi"] [--admin-email="info@emizentech.com"] [--admin-firstname="Emizen"] [--admin-lastname="Tech"] |
How to unlock admin user in Magento 2.0
Run following command from command line
1 |
bin/magento admin:user:unlock <adminusername> |
Magento 2.0 : static files links not working
Magento 2.0 is released, however there may be various issues that a Developer might go through.One of the prime concern would be: Broken Links for Static files like js, css & images etc. links will not work in following cases: Installation
New Extension : Magento 2 : Product Thumbnail in Sales Emails
This module will enable product image thumbnail on sales email. Download the code from Below URL emizentech:magento2-product-image-in-sales-emails Installation Email Images Module 1 Upload new module to Magento2 root folder run following commands: 2 Install New Module bin/magento module:enable EmizenTech_NewModule 3