Magento 2 PHP Fatal error: Class not found when compiling The 2019 Stack Overflow Developer Survey Results Are In Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Create beautiful image upload in configuration magento 2Fatal error “Call to undefined function” with __() when running unit test in magento2MiBPHP Fatal error While compilingClassnames 'Void' inside vendor/magento/Fatal error: Uncaught Error: Class 'Cli' not foundMagento 2 : Added field for image upload in admin formMagento 2: Captcha overwrite fatal error on PHP 7Magento 2 - PHP fatal errorerror on magento 2 after update php 5 to 7, Warning: require(/var/www/html/vendor/magento/framework/registration.php):?Magento 2 Fatal error: Uncaught Error: Class not foundFatal error: Uncaught RuntimeException:
Simulating Exploding Dice
60's-70's movie: home appliances revolting against the owners
Circular reasoning in L'Hopital's rule
What was the last x86 CPU that did not have the x87 floating-point unit built in?
Fixing different display colors within string
Huge performance difference of the command find with and without using %M option to show permissions
TDS update packages don't remove unneeded items
What's the point in a preamp?
How many Rusted Keys do you need to get red items most of the time?
Is 'stolen' appropriate word?
What happens to a Warlock's expended Spell Slots when they gain a Level?
Single author papers against my advisor's will?
"... to apply for a visa" or "... and applied for a visa"?
What do I do when my TA workload is more than expected?
Is it ok to offer lower paid work as a trial period before negotiating for a full-time job?
Voltage transmission
Why can't wing-mounted spoilers be used to steepen approaches?
Mortgage adviser recommends a longer term than necessary combined with overpayments
What other Star Trek series did the main TNG cast show up in?
Was credit for the black hole image misappropriated?
What does Linus Torvalds mean when he says that Git "never ever" tracks a file?
What does "spokes" mean in this context?
Make it rain characters
Windows 10: How to Lock (not sleep) laptop on lid close?
Magento 2 PHP Fatal error: Class not found when compiling
The 2019 Stack Overflow Developer Survey Results Are In
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Create beautiful image upload in configuration magento 2Fatal error “Call to undefined function” with __() when running unit test in magento2MiBPHP Fatal error While compilingClassnames 'Void' inside vendor/magento/Fatal error: Uncaught Error: Class 'Cli' not foundMagento 2 : Added field for image upload in admin formMagento 2: Captcha overwrite fatal error on PHP 7Magento 2 - PHP fatal errorerror on magento 2 after update php 5 to 7, Warning: require(/var/www/html/vendor/magento/framework/registration.php):?Magento 2 Fatal error: Uncaught Error: Class not foundFatal error: Uncaught RuntimeException:
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
When I compile I get this error:
PHP Fatal error: Class
'MagentoCatalogControllerAdminhtmlCategoryImageUpload' not found
in
/var/www/html/magento/app/code/Plazathemes/Override/Controller/Adminhtml/Category/Image/Upload.php
on line 11
EDIT with the code:

Still unable to fix can someone write the soltion to fix this.
magento2 magento-enterprise setup-di-compile
bumped to the homepage by Community♦ 2 days ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
When I compile I get this error:
PHP Fatal error: Class
'MagentoCatalogControllerAdminhtmlCategoryImageUpload' not found
in
/var/www/html/magento/app/code/Plazathemes/Override/Controller/Adminhtml/Category/Image/Upload.php
on line 11
EDIT with the code:

Still unable to fix can someone write the soltion to fix this.
magento2 magento-enterprise setup-di-compile
bumped to the homepage by Community♦ 2 days ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
Are you sure all composer packages are installed? If something is corrupt in your composer and you do composer install/update it won't fix it. You have to force reinstall that package. Try cleaning the vendor folder and run composer install or composer update
– Stijn Duynslaeger - Echron
Dec 29 '16 at 0:41
Can you please provide the steps to follow to do this.
– DiLjiT singh
Dec 29 '16 at 7:58
Did you removevar/di,var/generationand try run di compile again?
– Khoa TruongDinh
Dec 29 '16 at 14:44
Clear cache and generated files and again recompile. Hope this will help you
– Kishor Hase
Sep 25 '17 at 16:28
add a comment |
When I compile I get this error:
PHP Fatal error: Class
'MagentoCatalogControllerAdminhtmlCategoryImageUpload' not found
in
/var/www/html/magento/app/code/Plazathemes/Override/Controller/Adminhtml/Category/Image/Upload.php
on line 11
EDIT with the code:

Still unable to fix can someone write the soltion to fix this.
magento2 magento-enterprise setup-di-compile
When I compile I get this error:
PHP Fatal error: Class
'MagentoCatalogControllerAdminhtmlCategoryImageUpload' not found
in
/var/www/html/magento/app/code/Plazathemes/Override/Controller/Adminhtml/Category/Image/Upload.php
on line 11
EDIT with the code:

Still unable to fix can someone write the soltion to fix this.
magento2 magento-enterprise setup-di-compile
magento2 magento-enterprise setup-di-compile
edited Dec 29 '16 at 14:17
Khoa TruongDinh
22.2k64187
22.2k64187
asked Dec 28 '16 at 19:27
DiLjiT singhDiLjiT singh
2114
2114
bumped to the homepage by Community♦ 2 days ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
bumped to the homepage by Community♦ 2 days ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
Are you sure all composer packages are installed? If something is corrupt in your composer and you do composer install/update it won't fix it. You have to force reinstall that package. Try cleaning the vendor folder and run composer install or composer update
– Stijn Duynslaeger - Echron
Dec 29 '16 at 0:41
Can you please provide the steps to follow to do this.
– DiLjiT singh
Dec 29 '16 at 7:58
Did you removevar/di,var/generationand try run di compile again?
– Khoa TruongDinh
Dec 29 '16 at 14:44
Clear cache and generated files and again recompile. Hope this will help you
– Kishor Hase
Sep 25 '17 at 16:28
add a comment |
Are you sure all composer packages are installed? If something is corrupt in your composer and you do composer install/update it won't fix it. You have to force reinstall that package. Try cleaning the vendor folder and run composer install or composer update
– Stijn Duynslaeger - Echron
Dec 29 '16 at 0:41
Can you please provide the steps to follow to do this.
– DiLjiT singh
Dec 29 '16 at 7:58
Did you removevar/di,var/generationand try run di compile again?
– Khoa TruongDinh
Dec 29 '16 at 14:44
Clear cache and generated files and again recompile. Hope this will help you
– Kishor Hase
Sep 25 '17 at 16:28
Are you sure all composer packages are installed? If something is corrupt in your composer and you do composer install/update it won't fix it. You have to force reinstall that package. Try cleaning the vendor folder and run composer install or composer update
– Stijn Duynslaeger - Echron
Dec 29 '16 at 0:41
Are you sure all composer packages are installed? If something is corrupt in your composer and you do composer install/update it won't fix it. You have to force reinstall that package. Try cleaning the vendor folder and run composer install or composer update
– Stijn Duynslaeger - Echron
Dec 29 '16 at 0:41
Can you please provide the steps to follow to do this.
– DiLjiT singh
Dec 29 '16 at 7:58
Can you please provide the steps to follow to do this.
– DiLjiT singh
Dec 29 '16 at 7:58
Did you remove
var/di, var/generation and try run di compile again?– Khoa TruongDinh
Dec 29 '16 at 14:44
Did you remove
var/di, var/generation and try run di compile again?– Khoa TruongDinh
Dec 29 '16 at 14:44
Clear cache and generated files and again recompile. Hope this will help you
– Kishor Hase
Sep 25 '17 at 16:28
Clear cache and generated files and again recompile. Hope this will help you
– Kishor Hase
Sep 25 '17 at 16:28
add a comment |
3 Answers
3
active
oldest
votes
Seem that you're trying to override the class MagentoCatalogControllerAdminhtmlCategoryImageUpload. So, make sure your custom class will extend from this class.
class Upload extends MagentoCatalogControllerAdminhtmlCategoryImageUpload
......
add a comment |
Not sure why you are getting the error itself but if i may suggest just making your file like this?
namespace ....
use MagentoBackendAppAction;
use MagentoCatalogModelImageUploader;
class Upload extends Action
/**
* Image uploader
*
* @var MagentoCatalogModelImageUploader
*/
protected $imageUploader;
/**
* Upload constructor.
*
* @param ActionContext $context
* @param MagentoCatalogModelImageUploader $imageUploader
*/
public function __construct(
ActionContext $context,
ImageUploader $imageUploader
)
parent::__construct($context);
$this->imageUploader = $imageUploader;
public function execute()
....
I also suggest you use the Magento image uploader instead of the category uploader unless that is really your intention.
Like here
Create beautiful image upload in configuration magento 2
Just a comment. Since i do not know the intend or the page where you are using this i can not provide a specific solution but i hope this helps
– CompactCode
Mar 29 '18 at 2:49
add a comment |
Try to give a alias name for the extended class - as shown below:
use MagentoCatalogControllerAdminhtmlCategoryImageUpload as CatalogImageUopload
class Upload extends CatalogImageUopload
-----write your code here---
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "479"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f152244%2fmagento-2-php-fatal-error-class-not-found-when-compiling%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
Seem that you're trying to override the class MagentoCatalogControllerAdminhtmlCategoryImageUpload. So, make sure your custom class will extend from this class.
class Upload extends MagentoCatalogControllerAdminhtmlCategoryImageUpload
......
add a comment |
Seem that you're trying to override the class MagentoCatalogControllerAdminhtmlCategoryImageUpload. So, make sure your custom class will extend from this class.
class Upload extends MagentoCatalogControllerAdminhtmlCategoryImageUpload
......
add a comment |
Seem that you're trying to override the class MagentoCatalogControllerAdminhtmlCategoryImageUpload. So, make sure your custom class will extend from this class.
class Upload extends MagentoCatalogControllerAdminhtmlCategoryImageUpload
......
Seem that you're trying to override the class MagentoCatalogControllerAdminhtmlCategoryImageUpload. So, make sure your custom class will extend from this class.
class Upload extends MagentoCatalogControllerAdminhtmlCategoryImageUpload
......
answered Dec 29 '16 at 0:47
Khoa TruongDinhKhoa TruongDinh
22.2k64187
22.2k64187
add a comment |
add a comment |
Not sure why you are getting the error itself but if i may suggest just making your file like this?
namespace ....
use MagentoBackendAppAction;
use MagentoCatalogModelImageUploader;
class Upload extends Action
/**
* Image uploader
*
* @var MagentoCatalogModelImageUploader
*/
protected $imageUploader;
/**
* Upload constructor.
*
* @param ActionContext $context
* @param MagentoCatalogModelImageUploader $imageUploader
*/
public function __construct(
ActionContext $context,
ImageUploader $imageUploader
)
parent::__construct($context);
$this->imageUploader = $imageUploader;
public function execute()
....
I also suggest you use the Magento image uploader instead of the category uploader unless that is really your intention.
Like here
Create beautiful image upload in configuration magento 2
Just a comment. Since i do not know the intend or the page where you are using this i can not provide a specific solution but i hope this helps
– CompactCode
Mar 29 '18 at 2:49
add a comment |
Not sure why you are getting the error itself but if i may suggest just making your file like this?
namespace ....
use MagentoBackendAppAction;
use MagentoCatalogModelImageUploader;
class Upload extends Action
/**
* Image uploader
*
* @var MagentoCatalogModelImageUploader
*/
protected $imageUploader;
/**
* Upload constructor.
*
* @param ActionContext $context
* @param MagentoCatalogModelImageUploader $imageUploader
*/
public function __construct(
ActionContext $context,
ImageUploader $imageUploader
)
parent::__construct($context);
$this->imageUploader = $imageUploader;
public function execute()
....
I also suggest you use the Magento image uploader instead of the category uploader unless that is really your intention.
Like here
Create beautiful image upload in configuration magento 2
Just a comment. Since i do not know the intend or the page where you are using this i can not provide a specific solution but i hope this helps
– CompactCode
Mar 29 '18 at 2:49
add a comment |
Not sure why you are getting the error itself but if i may suggest just making your file like this?
namespace ....
use MagentoBackendAppAction;
use MagentoCatalogModelImageUploader;
class Upload extends Action
/**
* Image uploader
*
* @var MagentoCatalogModelImageUploader
*/
protected $imageUploader;
/**
* Upload constructor.
*
* @param ActionContext $context
* @param MagentoCatalogModelImageUploader $imageUploader
*/
public function __construct(
ActionContext $context,
ImageUploader $imageUploader
)
parent::__construct($context);
$this->imageUploader = $imageUploader;
public function execute()
....
I also suggest you use the Magento image uploader instead of the category uploader unless that is really your intention.
Like here
Create beautiful image upload in configuration magento 2
Not sure why you are getting the error itself but if i may suggest just making your file like this?
namespace ....
use MagentoBackendAppAction;
use MagentoCatalogModelImageUploader;
class Upload extends Action
/**
* Image uploader
*
* @var MagentoCatalogModelImageUploader
*/
protected $imageUploader;
/**
* Upload constructor.
*
* @param ActionContext $context
* @param MagentoCatalogModelImageUploader $imageUploader
*/
public function __construct(
ActionContext $context,
ImageUploader $imageUploader
)
parent::__construct($context);
$this->imageUploader = $imageUploader;
public function execute()
....
I also suggest you use the Magento image uploader instead of the category uploader unless that is really your intention.
Like here
Create beautiful image upload in configuration magento 2
answered Mar 29 '18 at 2:47
CompactCodeCompactCode
1,597725
1,597725
Just a comment. Since i do not know the intend or the page where you are using this i can not provide a specific solution but i hope this helps
– CompactCode
Mar 29 '18 at 2:49
add a comment |
Just a comment. Since i do not know the intend or the page where you are using this i can not provide a specific solution but i hope this helps
– CompactCode
Mar 29 '18 at 2:49
Just a comment. Since i do not know the intend or the page where you are using this i can not provide a specific solution but i hope this helps
– CompactCode
Mar 29 '18 at 2:49
Just a comment. Since i do not know the intend or the page where you are using this i can not provide a specific solution but i hope this helps
– CompactCode
Mar 29 '18 at 2:49
add a comment |
Try to give a alias name for the extended class - as shown below:
use MagentoCatalogControllerAdminhtmlCategoryImageUpload as CatalogImageUopload
class Upload extends CatalogImageUopload
-----write your code here---
add a comment |
Try to give a alias name for the extended class - as shown below:
use MagentoCatalogControllerAdminhtmlCategoryImageUpload as CatalogImageUopload
class Upload extends CatalogImageUopload
-----write your code here---
add a comment |
Try to give a alias name for the extended class - as shown below:
use MagentoCatalogControllerAdminhtmlCategoryImageUpload as CatalogImageUopload
class Upload extends CatalogImageUopload
-----write your code here---
Try to give a alias name for the extended class - as shown below:
use MagentoCatalogControllerAdminhtmlCategoryImageUpload as CatalogImageUopload
class Upload extends CatalogImageUopload
-----write your code here---
answered May 3 '18 at 9:39
Prasanta HatuiPrasanta Hatui
1,4501514
1,4501514
add a comment |
add a comment |
Thanks for contributing an answer to Magento Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f152244%2fmagento-2-php-fatal-error-class-not-found-when-compiling%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Are you sure all composer packages are installed? If something is corrupt in your composer and you do composer install/update it won't fix it. You have to force reinstall that package. Try cleaning the vendor folder and run composer install or composer update
– Stijn Duynslaeger - Echron
Dec 29 '16 at 0:41
Can you please provide the steps to follow to do this.
– DiLjiT singh
Dec 29 '16 at 7:58
Did you remove
var/di,var/generationand try run di compile again?– Khoa TruongDinh
Dec 29 '16 at 14:44
Clear cache and generated files and again recompile. Hope this will help you
– Kishor Hase
Sep 25 '17 at 16:28