Questions tagged [template]

The folder that contains all the `phtml` files used to display at frontend or backend.

Filter by
Sorted by
Tagged with
0
votes
1answer
30 views

Magento2 : Call phtml file to other phtml file

I want to add new phtml file to existed phtml file. It is working fine, but I want to know reference block and class names. My code in layout file <page xmlns:xsi="http://www.w3.org/2001/...
0
votes
1answer
27 views

Magento 2: Problem overriding product/view/form.phtml in custom module

I tried using this in my catalog_product_view.xml: <?xml version="1.0"?> <!-- /** * Copyright © Magento, Inc. All rights reserved. * See COPYING.txt for license details. */ -->...
0
votes
0answers
19 views

How to save a frontend user uploaded image in desired folder using knockout js

I want to put a file upload button in my gift message extended module(file path is: Vendor/Magento_GiftMessage/web/template/gift-message.html. I could add the button and display the image as well, now ...
0
votes
0answers
17 views

Access initialize function's variable in other function

I have a JS file where I am getting .phtml variable dates like: initialize: function (config) { dates = config.dates; this.test(); } test: function(){ //get variable dates } another: ...
0
votes
0answers
19 views

How to add color name before product name in mini-cart and right sidebar of checkout page in Magento 2

I want to show the color with the product name in Minicart and Checkout Page in Magento 2. So i have got the color value by <!-- ko if: options.length --> <!-- ko foreach: { ...
0
votes
4answers
25 views

Override custom extension adminhtml template in my module

I want to over ride following tramplete: app/code/Mageplaza/EditOrder/view/adminhtml/templates/order/edit/shipping/method/list.phtml Declared in : app/code/Mageplaza/EditOrder/view/adminhtml/layout/...
0
votes
1answer
10 views

Override skip.phtml results on langage switcher disappear

I'm trying to override template skip.phtml file (in the top of Magento) with this layout default.xml <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
0
votes
1answer
25 views

override adminhtml template

I would like to overide the following admin template src/vendor/magento/module-sales/view/adminhtml/templates/order/view/history.phtml This is what I made module.xml <config xmlns:xsi="http://...
0
votes
1answer
17 views

override html/skip.phtml template's block file

In layout default.xml, i found this <block class="Magento\Framework\View\Element\Template" name="skip_to_content" template="Magento_Theme::html/skip.phtml"> So ...
0
votes
1answer
22 views

if condition question in Magento for email template

I need help to verify my if statement, I am not sure in Magento of using "$block->escapeHtml($label)" in if condition is correct or not does my if statement correct for only showing "...
0
votes
0answers
43 views

How to overwrite the files in the "template" folder that contains the html files

How to overwrite a file in the "template" folder that contains html files? I'm not talking about the "templates" folder that contains the phtml files. I tried overwriting the same ...
1
vote
4answers
94 views

How to pass variable to $block->getChildHtml('form_additional_info')

I need to pass the customer object from the edit.phtml template to a child template: I have this but it does not work: <?php $block->getChildBlock('form_additional_info')->setData('customer', ...
0
votes
0answers
11 views

Error log showing a template file but module not found in my files

My Magento 2.2.6 Website is become very slow when we are adding product or updating product in backend and some time website is crashing . So when i check the log file i have found following error ...
0
votes
2answers
46 views

I want to call phtml file from Magento_Theme to static block. but it is giving some error

PHTML file is located in Magento_Theme/templates/html/breadcrumbs.phtml. I tried with the code {{block class="Magento\Framework\View\Element\Template" template="Magento_Theme::html\...
0
votes
0answers
15 views

I want to add swatch images from product page to home page product list

I want to add swatch images from product page to home page product list. swatch images from here to to here, replace the text"THIS is a custom" to swatch images How can I do this.
0
votes
1answer
18 views

Magento 2 Invoice Emails: Tax row alignment in subtotals

So I wanted to change the layout of my invoice emails, especially order totals. I wanted labels to align right. I copied my totals.phtml file in my theme and added my styling. <?php /** * ...
0
votes
0answers
12 views

Can't override a renderer template in sales_order_item_renderer.xml

I have already checked a lot of posts about overriding item renderers (and some of them really work in places like e-mail and checkout), but I can't override a template in sales_order_item_renderers....
0
votes
1answer
238 views

Adding Meta tags to the head of a CMS page Magento 2.3.6

In order to add the following meta tags to the home page I have done the followings: <meta property="og:image" content="https://example.com/media/wysiwyg/abc.png"> <meta ...
1
vote
1answer
19 views

Calling the welcome message in different template?

Is it possible to call the default welcome message when user is logged in ("Welcome, customer.fullname") in a different .phtml? I'd need this message in my Magento_Customer/templates/account/...
1
vote
1answer
165 views

How to add Custom Step on Checkout and move Shipping methods in that step In Magento 2.3.5

In this i want one custom checkout step can having only shipping methods inside the step means shipping address and Shipping methods are on different steps on checkout page. So, Please can anyone have ...
0
votes
0answers
25 views

How to get dial code from selected country in textbox before telephone filed using knockout js

I want to develop functionality in that i have created one field for country dial code on checkout page and according to changes of country dropdown dial code will be changes automatically in that ...
0
votes
1answer
44 views

Magento 2 - Show validation message in custom container on product update page

I try to show the validation message which shows if you enter a wrong value (for example 0) and try to add the product to the cart, in a custom place. I try to do this on the product update site, ...
0
votes
0answers
32 views

Magento 2 how to use step navigator of checkout in a custom template?

I'm trying to use the checkout step navigator bar in another template. I tried this but did not work, it just shows buttons: in phtml. <div id="steps" data-bind="scope:'steps'"&...
0
votes
1answer
102 views

How can i insert custom tracking url in Order confirmation Email Template?

I want to insert my custom tracking url in Order Confirmation email and url is https://vitalticks.shiprocket.co i put code like this Track you Order here:Vitalticks Order Tracking Page But it is not ...
0
votes
0answers
17 views

Magento 2 How to send data from one html template to another?

I'm developing 2 forms with knockout js and html template. This 2 forms templates need to be separated, however they share data in common, for example, coverages amounts (this templates are about ...
0
votes
0answers
22 views

Magento 2 send data from html template to Controller without Ajax

So I have created a component which has 2 templates, but the property data is the same for both. I wanted to know if there is a way to send data without using ajax. Why? Because I don't need to use ...
2
votes
1answer
127 views

Magento 2 Custom template content will not shown in graphql response of CMS page

I have a CMS page in which I want to show the date e.i Current date OR Date after 5 days etc. So for that I have created a template file and call inside the CMS page. It will show content in Front but ...
0
votes
2answers
20 views

Invalid template file: 'Company_module::menubtn.phtml' in module: '' block's name: 'custom_menu'

I want display a phtml file in the header, i created a phtml file and called in the default.xml but it is giving invalid template file block's name, what should be give as a block name menubtn.phtml &...
0
votes
3answers
172 views

Magento 2 - Get name of templates block from .phtml file

Is it possible to get the block name of the current template? For example I added a block to catalog_product_view.xml: <block class="Magento\Contact\Block\ContactForm" name="...
1
vote
4answers
82 views

Magento 2 : override template file

Is their any way we can override below template file Magento_Sales::email/items/order/default.phtml which is defined in vendor/magento/module-gift-card/view/frontend/layout/...
0
votes
1answer
28 views

Email address variable causing items to disappear from email template

I've inserted a variable to bring in the customer email into the default new order template however when I added this I noticed that the items and total amount now disappear - any idea what's going on?...
3
votes
4answers
230 views

Magento 2 : Override template file /info/default.phtml

How to override below file in module ? Magento2/vendor/magento/module-payment/view/frontend/templates/info/default.phtml
0
votes
1answer
16 views

Magento two cannot update sales_order_create_load_block_items.xml

I need to overwrite Magento_Sales::order/create/items/grid.phtml in sales_order_create_load_block_items.xml created My_Module/view/adminhtml/sales_order_create_load_block_items.xml <?xml ...
0
votes
1answer
83 views

Magento 2 : override Magento_Sales::email/items/creditmemo/default.phtml

What is the best way to override below template file in module ? Magento_Sales::email/items/creditmemo/default.phtml
0
votes
1answer
49 views

Magento 2: Override Magento_Payment::info/default.phtml

What is the best way to Override Magento_Payment::info/default.phtml in module ?
0
votes
1answer
313 views

Magento 2 : Override email/shipment/track.phtml in module

Is their any way we can override email/shipment/track.phtml ? in module ? created layout file view/frontend/layout/sales_email_order_shipment_track.xml <?xml version="1.0"?> <page ...
0
votes
0answers
16 views

Shipment email template amendment

I am trying to amend our shipment email template so it will show a list of items NOT YET DISPATCHED (if applicable) - call it a backorder list if you like. Does anybody know how I can do this? Thanks ...
0
votes
2answers
211 views

Can't override list.phtml in Magento 2.4

I try to override the list.phtml in Magento 2.4 but it's not working. Here is the path to my new file : app/design/frontend/Magento/timeote/Magento_Catalog/templates/product/list.phtml All the other ...
0
votes
0answers
10 views

Making A costume PDF invoice

I am new to magento 2 and want to customize my invoice PDF that is created, I want to change the design completely and want to add new field also I want to make a conditional paragraph that shows in ...
0
votes
0answers
15 views

Sort By option not working properly when using ascending or descending button

So the problem is as follows: I have the Sort By option set to "Price", but once i try to change the order from descending to ascending or vice versa, the Sort By" turns back to ...
0
votes
0answers
24 views

Magento 2 - How to customize "new address" form in checkout?

In magento you can add a new address during the checkout process. I need to add a little text at the position seen in the screenshot: I can't figure out how this is done. I've read through the ...
0
votes
1answer
35 views

How to add attribute to product grid?

I would like to add the sku attribute to my product widget. Here is the original Magento code- <?php /** * Copyright © Magento, Inc. All rights reserved. * See COPYING.txt for license details. */ ...
0
votes
1answer
24 views

Magento 2 - Conflict in localisation csv file

I understand the general structure of i18n csv files that is like <key_hook>,<translation_of_that_key> but according to the documentation there is the possibility to add a module ...
0
votes
1answer
24 views

ViewModel modification makes existing list.phtml break

I recently made a modification to catalog-category-view.xml and overrode category.products.list. It seemed to work at the time, I had badges displaying on a rendered page. Now the template file errors ...
0
votes
1answer
26 views

Sending Email with custom header,footer

I want to create a custom header and footer for email templates. currently when the user receives an email the logo in the head redirects it to the store URL but I want it to redirect to somewhere ...
0
votes
0answers
11 views

Before the control rendering tier price template, how to check whether the product having tier price or not in magento 2

How the magento control checks whether the product render the tier price template or regular price template ? How can we do some functionality, before the control reads price template ?
0
votes
0answers
23 views

Apply special template for product page

I would like to apply special template file following an admin product configuration, for example, I have a dropdown product configuration list named layout which have two options: total and normal, ...
0
votes
2answers
23 views

Where is the template file for the front-end grid view in Magento 2.3?

I need to overwrite the front-end grid view but cannot find the correct file. This is the grid view that appears as a front end option for categories and search - not the admin grid.
0
votes
1answer
44 views

Use different phtml for single product

I understand this is probably very simple, but I have thoroughly confused myself and am hoping someone has a few minutes to provide clarity. I would like to apply some very, very custom stuff to a ...
0
votes
1answer
153 views

Is there a way not to loose input form data on php redirect

I have a webpage with a form when I submit that page I go into a controller...he check the data sent $data = $this->getRequest()->getPostValue(); And if one of the data isn't what I am expecting,...

1
2 3 4 5
28