Magento 2 : checkout_cart_index.xml problemMagento 2 Override Shipping TemplateMagento 2 - Update Cart Block...
Why do no American passenger airlines still operate dedicated cargo flights?
How to remove lines through the legend markers in ListPlot?
How to count the characters of jar files by wc
Can making a creature unable to attack after it has been assigned as an attacker remove it from combat?
Why would the Pakistan airspace closure cancel flights not headed to Pakistan itself?
Why avoid shared user accounts?
Publishing research using outdated methods
Can I use a mote from Crown of Stars to attack and also cast Eldritch Blast on the same turn?
Avoiding morning and evening handshakes
How much mayhem could I cause as a sentient fish?
Why did other German political parties disband so fast when Hitler was appointed chancellor?
What is the purpose of easy combat scenarios that don't need resource expenditure?
What is 6÷2×(1+2) =?
My cat mixes up the floors in my building. How can I help him?
Can I string the D&D Starter Set campaign into another module, keeping the same characters?
Why has the mole been redefined for 2019?
Why are the books in the Game of Thrones citadel library shelved spine inwards?
How to say "Brexit" in Latin?
Finding a mistake using Mayer-Vietoris
How to solve a large system of linear algebra?
Caruana vs Carlsen game 10 (WCC) why not 18...Nxb6?
Which one of these password policies is more secure?
In Linux what happens if 1000 files in a directory are moved to another location while another 300 files were added to the source directory?
Intern applicant asking for compensation equivalent to that of permanent employee
Magento 2 : checkout_cart_index.xml problem
Magento 2 Override Shipping TemplateMagento 2 - Update Cart Block with Custom Discount ValueAre we forced to rewrite a template in Magento2 when rewritting a block?Override module-contact view and controllerMagento 2: Adding a new Block to Checkout_Cart_Item_RendererCreate a horizontal menu into a block using megamenuMagento2: Apply coupon code to regular price not to special priceGENERATE THIS REPORT: main.INFO: Cache file with merged layout: LAYOUT_adminhtml_STORE1_Move/Push page.main.title block into Breadcrumbs Magento2Working of discount coupons on the checkout page in Magento 2.2.2
When I copy checkout_cart_index.xml
page to my theme it works fine but when I change
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Checkout::cart/form.phtml" after="cart.summary">
to
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Theme::cart/form.phtml" after="cart.summary">
For overriding a template file from my theme the discount coupon form disappears and it also disappears from from html too.
Thanks in advance.
magento2 layout
add a comment |
When I copy checkout_cart_index.xml
page to my theme it works fine but when I change
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Checkout::cart/form.phtml" after="cart.summary">
to
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Theme::cart/form.phtml" after="cart.summary">
For overriding a template file from my theme the discount coupon form disappears and it also disappears from from html too.
Thanks in advance.
magento2 layout
1
only phtml file override as your theme path folder not to xml file need to override.
– Vijay-CyberLocker
Feb 21 '18 at 12:40
If I do not override XML theme path it get template from module_checkout rather than my custom_theme
– Abdullah Shahid
Feb 21 '18 at 13:10
add a comment |
When I copy checkout_cart_index.xml
page to my theme it works fine but when I change
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Checkout::cart/form.phtml" after="cart.summary">
to
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Theme::cart/form.phtml" after="cart.summary">
For overriding a template file from my theme the discount coupon form disappears and it also disappears from from html too.
Thanks in advance.
magento2 layout
When I copy checkout_cart_index.xml
page to my theme it works fine but when I change
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Checkout::cart/form.phtml" after="cart.summary">
to
<block class="MagentoCheckoutBlockCartGrid" name="checkout.cart.form" as="cart-items" template="Magento_Theme::cart/form.phtml" after="cart.summary">
For overriding a template file from my theme the discount coupon form disappears and it also disappears from from html too.
Thanks in advance.
magento2 layout
magento2 layout
edited Feb 21 '18 at 14:03
Matt Antley
1,061518
1,061518
asked Feb 21 '18 at 12:33
Abdullah ShahidAbdullah Shahid
7910
7910
1
only phtml file override as your theme path folder not to xml file need to override.
– Vijay-CyberLocker
Feb 21 '18 at 12:40
If I do not override XML theme path it get template from module_checkout rather than my custom_theme
– Abdullah Shahid
Feb 21 '18 at 13:10
add a comment |
1
only phtml file override as your theme path folder not to xml file need to override.
– Vijay-CyberLocker
Feb 21 '18 at 12:40
If I do not override XML theme path it get template from module_checkout rather than my custom_theme
– Abdullah Shahid
Feb 21 '18 at 13:10
1
1
only phtml file override as your theme path folder not to xml file need to override.
– Vijay-CyberLocker
Feb 21 '18 at 12:40
only phtml file override as your theme path folder not to xml file need to override.
– Vijay-CyberLocker
Feb 21 '18 at 12:40
If I do not override XML theme path it get template from module_checkout rather than my custom_theme
– Abdullah Shahid
Feb 21 '18 at 13:10
If I do not override XML theme path it get template from module_checkout rather than my custom_theme
– Abdullah Shahid
Feb 21 '18 at 13:10
add a comment |
2 Answers
2
active
oldest
votes
If you want to override the the .phtml template file try to put your form.phtml
file inside
app/design/frontend/YourVendorThemeName/YourAciveThemeName/Magento_Checkout/templates/cart/form.phtml
You should use setTemplate
action in layout xml file, if you want to override phtml from your custom module
checkout_cart_index.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="checkout.cart.form">
<action method="setTemplate">
<argument name="template" xsi:type="string">Magento_Theme::cart/form.phtml</argument>
</action>
</referenceBlock>
</body>
</page>
add a comment |
All I do is move checkout.cart.coupon to my container and it is was apparent where I want. Here is the code
<move element="checkout.cart.coupon" destination="summary-col1" before="-"/>
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%2f214439%2fmagento-2-checkout-cart-index-xml-problem%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
If you want to override the the .phtml template file try to put your form.phtml
file inside
app/design/frontend/YourVendorThemeName/YourAciveThemeName/Magento_Checkout/templates/cart/form.phtml
You should use setTemplate
action in layout xml file, if you want to override phtml from your custom module
checkout_cart_index.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="checkout.cart.form">
<action method="setTemplate">
<argument name="template" xsi:type="string">Magento_Theme::cart/form.phtml</argument>
</action>
</referenceBlock>
</body>
</page>
add a comment |
If you want to override the the .phtml template file try to put your form.phtml
file inside
app/design/frontend/YourVendorThemeName/YourAciveThemeName/Magento_Checkout/templates/cart/form.phtml
You should use setTemplate
action in layout xml file, if you want to override phtml from your custom module
checkout_cart_index.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="checkout.cart.form">
<action method="setTemplate">
<argument name="template" xsi:type="string">Magento_Theme::cart/form.phtml</argument>
</action>
</referenceBlock>
</body>
</page>
add a comment |
If you want to override the the .phtml template file try to put your form.phtml
file inside
app/design/frontend/YourVendorThemeName/YourAciveThemeName/Magento_Checkout/templates/cart/form.phtml
You should use setTemplate
action in layout xml file, if you want to override phtml from your custom module
checkout_cart_index.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="checkout.cart.form">
<action method="setTemplate">
<argument name="template" xsi:type="string">Magento_Theme::cart/form.phtml</argument>
</action>
</referenceBlock>
</body>
</page>
If you want to override the the .phtml template file try to put your form.phtml
file inside
app/design/frontend/YourVendorThemeName/YourAciveThemeName/Magento_Checkout/templates/cart/form.phtml
You should use setTemplate
action in layout xml file, if you want to override phtml from your custom module
checkout_cart_index.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="checkout.cart.form">
<action method="setTemplate">
<argument name="template" xsi:type="string">Magento_Theme::cart/form.phtml</argument>
</action>
</referenceBlock>
</body>
</page>
edited Feb 21 '18 at 14:24
answered Feb 21 '18 at 14:18
Idham ChoudryIdham Choudry
1,27811038
1,27811038
add a comment |
add a comment |
All I do is move checkout.cart.coupon to my container and it is was apparent where I want. Here is the code
<move element="checkout.cart.coupon" destination="summary-col1" before="-"/>
add a comment |
All I do is move checkout.cart.coupon to my container and it is was apparent where I want. Here is the code
<move element="checkout.cart.coupon" destination="summary-col1" before="-"/>
add a comment |
All I do is move checkout.cart.coupon to my container and it is was apparent where I want. Here is the code
<move element="checkout.cart.coupon" destination="summary-col1" before="-"/>
All I do is move checkout.cart.coupon to my container and it is was apparent where I want. Here is the code
<move element="checkout.cart.coupon" destination="summary-col1" before="-"/>
edited 42 mins ago
Teja Bhagavan Kollepara
2,96341847
2,96341847
answered Feb 22 '18 at 8:09
Abdullah ShahidAbdullah Shahid
7910
7910
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%2f214439%2fmagento-2-checkout-cart-index-xml-problem%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
1
only phtml file override as your theme path folder not to xml file need to override.
– Vijay-CyberLocker
Feb 21 '18 at 12:40
If I do not override XML theme path it get template from module_checkout rather than my custom_theme
– Abdullah Shahid
Feb 21 '18 at 13:10