Paypal Controller Overriding/Extending not workingPayPal Preconditions and EncryptionAccount Controller Overriding/Extending not workingExtending an abstract block classOverride Adminhtml importexport dataflow Profile ControllerHow to override the controller AccountControllerCreate Simple Controller Not Working In My Module in Magento 1.9.2?Magento controller override not working in other systemsrewrite block not workingM1 CE, paypal exception “PayPal NVP gateway errors”Magento problem in extension
Why weren't Gemini capsules given names?
How come a desk dictionary be abridged?
How did Captain Marvel do this without dying?
Why do Martians have to wear space helmets?
Do intermediate subdomains need to exist?
Does the Milky Way orbit around anything?
How can select a specific triangle in my Delaunay mesh?
How do I check that users don't write down their passwords?
SQL Server - TRY/CATCH does not work in certain cases
Is kapton suitable for use as high voltage insulation?
Is の方 necessary here?
Is it bad to suddenly introduce another element to your fantasy world a good ways into the story?
Should I warn my boss I might take sick leave?
I'm feeling like my character doesn't fit the campaign
Can you take the Dodge action while prone?
Is there a way to change the aspect ratio of a DNG file?
Are "confidant" and "confident" homophones?
Do Goblin tokens count as Goblins?
Do the 26 richest billionaires own as much wealth as the poorest 3.8 billion people?
soda water first stored in refrigerator and then outside
What is the difference between an "empty interior" and a "hole" in topology?
Is this standard Japanese employment negotiations, or am I missing something?
Should I increase my 401(k) contributions, or increase my mortgage payments
Stay in US on J-1 visa after quitting job?
Paypal Controller Overriding/Extending not working
PayPal Preconditions and EncryptionAccount Controller Overriding/Extending not workingExtending an abstract block classOverride Adminhtml importexport dataflow Profile ControllerHow to override the controller AccountControllerCreate Simple Controller Not Working In My Module in Magento 1.9.2?Magento controller override not working in other systemsrewrite block not workingM1 CE, paypal exception “PayPal NVP gateway errors”Magento problem in extension
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I have Magento 1.9 CE and I'm trying to create a new module for extend the class Mage_Paypal_Controller_Express_Abstract
, but it doesn't work.
Here's the code:
Name_Module.xml
in /app/etc/modules
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<active>true</active>
<codePool>local</codePool>
<depends></depends>
</Name_Module>
</modules>
</config>
config.xml
from /app/code/local/Name/Module/etc/
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<version>1.0.0</version>
</Name_Module>
</modules>
<frontend>
<routers>
<paypal>
<args>
<modules>
<Name_Module before="Mage_Paypal">Name_Module _Paypal</Name_Module >
</modules>
</args>
</paypal>
</routers>
</frontend>
and Abstract.php
app/code/local/Name//Controller/Paypal/Express/
<?php
include_once('Mage/Paypal/Controller/Express/Abstract.php');
class Name_Module_Paypal_Express_Abstract extends Mage_Paypal_Controller_Express_Abstract
/**
* Submit the order
*/
public function placeOrderAction()
//code
Why doesn't it work?
magento-1.9 paypal-express core
add a comment |
I have Magento 1.9 CE and I'm trying to create a new module for extend the class Mage_Paypal_Controller_Express_Abstract
, but it doesn't work.
Here's the code:
Name_Module.xml
in /app/etc/modules
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<active>true</active>
<codePool>local</codePool>
<depends></depends>
</Name_Module>
</modules>
</config>
config.xml
from /app/code/local/Name/Module/etc/
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<version>1.0.0</version>
</Name_Module>
</modules>
<frontend>
<routers>
<paypal>
<args>
<modules>
<Name_Module before="Mage_Paypal">Name_Module _Paypal</Name_Module >
</modules>
</args>
</paypal>
</routers>
</frontend>
and Abstract.php
app/code/local/Name//Controller/Paypal/Express/
<?php
include_once('Mage/Paypal/Controller/Express/Abstract.php');
class Name_Module_Paypal_Express_Abstract extends Mage_Paypal_Controller_Express_Abstract
/**
* Submit the order
*/
public function placeOrderAction()
//code
Why doesn't it work?
magento-1.9 paypal-express core
"it doesn't work". What doesn't work? What should it do and doesn't do? Please describe any faults, errors (add error logs), screenshots, etc...
– 7ochem
Sep 15 '15 at 11:09
use<depends>Mage_Paypal</depends>
instead of<depends></depends>
– Amit Bera♦
Sep 15 '15 at 11:32
add a comment |
I have Magento 1.9 CE and I'm trying to create a new module for extend the class Mage_Paypal_Controller_Express_Abstract
, but it doesn't work.
Here's the code:
Name_Module.xml
in /app/etc/modules
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<active>true</active>
<codePool>local</codePool>
<depends></depends>
</Name_Module>
</modules>
</config>
config.xml
from /app/code/local/Name/Module/etc/
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<version>1.0.0</version>
</Name_Module>
</modules>
<frontend>
<routers>
<paypal>
<args>
<modules>
<Name_Module before="Mage_Paypal">Name_Module _Paypal</Name_Module >
</modules>
</args>
</paypal>
</routers>
</frontend>
and Abstract.php
app/code/local/Name//Controller/Paypal/Express/
<?php
include_once('Mage/Paypal/Controller/Express/Abstract.php');
class Name_Module_Paypal_Express_Abstract extends Mage_Paypal_Controller_Express_Abstract
/**
* Submit the order
*/
public function placeOrderAction()
//code
Why doesn't it work?
magento-1.9 paypal-express core
I have Magento 1.9 CE and I'm trying to create a new module for extend the class Mage_Paypal_Controller_Express_Abstract
, but it doesn't work.
Here's the code:
Name_Module.xml
in /app/etc/modules
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<active>true</active>
<codePool>local</codePool>
<depends></depends>
</Name_Module>
</modules>
</config>
config.xml
from /app/code/local/Name/Module/etc/
<?xml version="1.0"?>
<config>
<modules>
<Name_Module>
<version>1.0.0</version>
</Name_Module>
</modules>
<frontend>
<routers>
<paypal>
<args>
<modules>
<Name_Module before="Mage_Paypal">Name_Module _Paypal</Name_Module >
</modules>
</args>
</paypal>
</routers>
</frontend>
and Abstract.php
app/code/local/Name//Controller/Paypal/Express/
<?php
include_once('Mage/Paypal/Controller/Express/Abstract.php');
class Name_Module_Paypal_Express_Abstract extends Mage_Paypal_Controller_Express_Abstract
/**
* Submit the order
*/
public function placeOrderAction()
//code
Why doesn't it work?
magento-1.9 paypal-express core
magento-1.9 paypal-express core
edited Sep 15 '15 at 11:08
7ochem
5,9499 gold badges37 silver badges70 bronze badges
5,9499 gold badges37 silver badges70 bronze badges
asked Sep 15 '15 at 11:04
OblomovaOblomova
61 bronze badge
61 bronze badge
"it doesn't work". What doesn't work? What should it do and doesn't do? Please describe any faults, errors (add error logs), screenshots, etc...
– 7ochem
Sep 15 '15 at 11:09
use<depends>Mage_Paypal</depends>
instead of<depends></depends>
– Amit Bera♦
Sep 15 '15 at 11:32
add a comment |
"it doesn't work". What doesn't work? What should it do and doesn't do? Please describe any faults, errors (add error logs), screenshots, etc...
– 7ochem
Sep 15 '15 at 11:09
use<depends>Mage_Paypal</depends>
instead of<depends></depends>
– Amit Bera♦
Sep 15 '15 at 11:32
"it doesn't work". What doesn't work? What should it do and doesn't do? Please describe any faults, errors (add error logs), screenshots, etc...
– 7ochem
Sep 15 '15 at 11:09
"it doesn't work". What doesn't work? What should it do and doesn't do? Please describe any faults, errors (add error logs), screenshots, etc...
– 7ochem
Sep 15 '15 at 11:09
use
<depends>Mage_Paypal</depends>
instead of <depends></depends>
– Amit Bera♦
Sep 15 '15 at 11:32
use
<depends>Mage_Paypal</depends>
instead of <depends></depends>
– Amit Bera♦
Sep 15 '15 at 11:32
add a comment |
3 Answers
3
active
oldest
votes
You can't overwrite an Abstract class in Magento. The class that you are trying to overwrite Mage_Paypal_Controller_Express_Abstract
is an abstract class and hence can't rewrite by controller-rewrite way.
If you want to edit placeOrderAction()
, the only possible way is put that core file in local
codepool. For this :
- Create a file
appcodelocalMagePaypalControllerExpressAbstract.php
- Copy paste original content of the file
Abstarct.php
to this file. - Now edit
placeOrderAction()
according to your need.
add a comment |
In Magenton abstract class does not override ....SO you can not rewrite class
Mage_Paypal_Controller_Express_Abstract....
Also there lot issue in code;
use <depends>Mage_Paypal</depends>
instead of <depends></depends>
unfortunately nothing changes
– Oblomova
Sep 15 '15 at 13:12
add a comment |
Mage_Paypal_Controller_Express_Abstract
is a basic class which implements common methods, you dont need to rewrite it.
Instead you need to define which payment method you want to modify excalty. In your case I suppose it is a Mage_Paypal_ExpressController
.
So, all you need to rewrite Mage_Paypal_ExpressController
class and implement own logic for method placeOrderAction()
.
It will work because Mage_Paypal_ExpressController
extends Mage_Paypal_Controller_Express_Abstract
and all methods you define in Mage_Paypal_ExpressController
will replace methods from parent class.
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%2f83171%2fpaypal-controller-overriding-extending-not-working%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
You can't overwrite an Abstract class in Magento. The class that you are trying to overwrite Mage_Paypal_Controller_Express_Abstract
is an abstract class and hence can't rewrite by controller-rewrite way.
If you want to edit placeOrderAction()
, the only possible way is put that core file in local
codepool. For this :
- Create a file
appcodelocalMagePaypalControllerExpressAbstract.php
- Copy paste original content of the file
Abstarct.php
to this file. - Now edit
placeOrderAction()
according to your need.
add a comment |
You can't overwrite an Abstract class in Magento. The class that you are trying to overwrite Mage_Paypal_Controller_Express_Abstract
is an abstract class and hence can't rewrite by controller-rewrite way.
If you want to edit placeOrderAction()
, the only possible way is put that core file in local
codepool. For this :
- Create a file
appcodelocalMagePaypalControllerExpressAbstract.php
- Copy paste original content of the file
Abstarct.php
to this file. - Now edit
placeOrderAction()
according to your need.
add a comment |
You can't overwrite an Abstract class in Magento. The class that you are trying to overwrite Mage_Paypal_Controller_Express_Abstract
is an abstract class and hence can't rewrite by controller-rewrite way.
If you want to edit placeOrderAction()
, the only possible way is put that core file in local
codepool. For this :
- Create a file
appcodelocalMagePaypalControllerExpressAbstract.php
- Copy paste original content of the file
Abstarct.php
to this file. - Now edit
placeOrderAction()
according to your need.
You can't overwrite an Abstract class in Magento. The class that you are trying to overwrite Mage_Paypal_Controller_Express_Abstract
is an abstract class and hence can't rewrite by controller-rewrite way.
If you want to edit placeOrderAction()
, the only possible way is put that core file in local
codepool. For this :
- Create a file
appcodelocalMagePaypalControllerExpressAbstract.php
- Copy paste original content of the file
Abstarct.php
to this file. - Now edit
placeOrderAction()
according to your need.
answered Sep 17 '15 at 8:08
Rajeev K TomyRajeev K Tomy
14.7k5 gold badges45 silver badges91 bronze badges
14.7k5 gold badges45 silver badges91 bronze badges
add a comment |
add a comment |
In Magenton abstract class does not override ....SO you can not rewrite class
Mage_Paypal_Controller_Express_Abstract....
Also there lot issue in code;
use <depends>Mage_Paypal</depends>
instead of <depends></depends>
unfortunately nothing changes
– Oblomova
Sep 15 '15 at 13:12
add a comment |
In Magenton abstract class does not override ....SO you can not rewrite class
Mage_Paypal_Controller_Express_Abstract....
Also there lot issue in code;
use <depends>Mage_Paypal</depends>
instead of <depends></depends>
unfortunately nothing changes
– Oblomova
Sep 15 '15 at 13:12
add a comment |
In Magenton abstract class does not override ....SO you can not rewrite class
Mage_Paypal_Controller_Express_Abstract....
Also there lot issue in code;
use <depends>Mage_Paypal</depends>
instead of <depends></depends>
In Magenton abstract class does not override ....SO you can not rewrite class
Mage_Paypal_Controller_Express_Abstract....
Also there lot issue in code;
use <depends>Mage_Paypal</depends>
instead of <depends></depends>
edited Sep 15 '15 at 12:50
Renon Stewart
12.2k1 gold badge20 silver badges44 bronze badges
12.2k1 gold badge20 silver badges44 bronze badges
answered Sep 15 '15 at 11:36
Amit Bera♦Amit Bera
61.7k16 gold badges84 silver badges183 bronze badges
61.7k16 gold badges84 silver badges183 bronze badges
unfortunately nothing changes
– Oblomova
Sep 15 '15 at 13:12
add a comment |
unfortunately nothing changes
– Oblomova
Sep 15 '15 at 13:12
unfortunately nothing changes
– Oblomova
Sep 15 '15 at 13:12
unfortunately nothing changes
– Oblomova
Sep 15 '15 at 13:12
add a comment |
Mage_Paypal_Controller_Express_Abstract
is a basic class which implements common methods, you dont need to rewrite it.
Instead you need to define which payment method you want to modify excalty. In your case I suppose it is a Mage_Paypal_ExpressController
.
So, all you need to rewrite Mage_Paypal_ExpressController
class and implement own logic for method placeOrderAction()
.
It will work because Mage_Paypal_ExpressController
extends Mage_Paypal_Controller_Express_Abstract
and all methods you define in Mage_Paypal_ExpressController
will replace methods from parent class.
add a comment |
Mage_Paypal_Controller_Express_Abstract
is a basic class which implements common methods, you dont need to rewrite it.
Instead you need to define which payment method you want to modify excalty. In your case I suppose it is a Mage_Paypal_ExpressController
.
So, all you need to rewrite Mage_Paypal_ExpressController
class and implement own logic for method placeOrderAction()
.
It will work because Mage_Paypal_ExpressController
extends Mage_Paypal_Controller_Express_Abstract
and all methods you define in Mage_Paypal_ExpressController
will replace methods from parent class.
add a comment |
Mage_Paypal_Controller_Express_Abstract
is a basic class which implements common methods, you dont need to rewrite it.
Instead you need to define which payment method you want to modify excalty. In your case I suppose it is a Mage_Paypal_ExpressController
.
So, all you need to rewrite Mage_Paypal_ExpressController
class and implement own logic for method placeOrderAction()
.
It will work because Mage_Paypal_ExpressController
extends Mage_Paypal_Controller_Express_Abstract
and all methods you define in Mage_Paypal_ExpressController
will replace methods from parent class.
Mage_Paypal_Controller_Express_Abstract
is a basic class which implements common methods, you dont need to rewrite it.
Instead you need to define which payment method you want to modify excalty. In your case I suppose it is a Mage_Paypal_ExpressController
.
So, all you need to rewrite Mage_Paypal_ExpressController
class and implement own logic for method placeOrderAction()
.
It will work because Mage_Paypal_ExpressController
extends Mage_Paypal_Controller_Express_Abstract
and all methods you define in Mage_Paypal_ExpressController
will replace methods from parent class.
answered Apr 16 '18 at 10:33
Sergey RepinSergey Repin
2111 silver badge2 bronze badges
2111 silver badge2 bronze badges
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%2f83171%2fpaypal-controller-overriding-extending-not-working%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
"it doesn't work". What doesn't work? What should it do and doesn't do? Please describe any faults, errors (add error logs), screenshots, etc...
– 7ochem
Sep 15 '15 at 11:09
use
<depends>Mage_Paypal</depends>
instead of<depends></depends>
– Amit Bera♦
Sep 15 '15 at 11:32