cancel
Showing results for 
Search instead for 
Did you mean: 

error during custom module development

SOLVED

error during custom module development

when i created a custom module in magento 2.2.3 on locahost i go the error:

Parse error: syntax error, unexpected ''Magenticians_Mymodule'' (T_CONSTANT_ENCAPSED_STRING), expecting ',' or ')' in C:\xampp\htdocs\magento3\app\code\Magenticians\Mymodule\registration.php on line 5

please help me to resolve this error

1 ACCEPTED SOLUTION

Accepted Solutions

Re: error during custom module development

Keep  below code in your registration.php file,

<?php
\Magento\Framework\Component\ComponentRegistrar::register(
    \Magento\Framework\Component\ComponentRegistrar::MODULE,
    'Magenticians_Mymodule',
    __DIR__
);
If Issue Solved, Click Kudos/Accept As solutions. Get Magento insight from
Magento 2 Blogs/Tutorial

View solution in original post

2 REPLIES 2

Re: error during custom module development

Hello @shweta_singh1

 

Seems like ) missing of.

 

Please open file and check again.

 

Hope it will help you.


Problem solved? Click Kudos & Accept as Solution!
Sunil Patel
Magento 2 Certified Professional Developer & Frontend Developer

Re: error during custom module development

Keep  below code in your registration.php file,

<?php
\Magento\Framework\Component\ComponentRegistrar::register(
    \Magento\Framework\Component\ComponentRegistrar::MODULE,
    'Magenticians_Mymodule',
    __DIR__
);
If Issue Solved, Click Kudos/Accept As solutions. Get Magento insight from
Magento 2 Blogs/Tutorial