I need to add new custom link fields(chat) in header tab.
For example luma page has these link fields in header page (create account, signup), same header place i want to add chat link in header top, suggest me how to do this.
Magento Stack Exchange is a question and answer site for users of the Magento e-Commerce platform. It only takes a minute to sign up.
Sign up to join this communityI need to add new custom link fields(chat) in header tab.
For example luma page has these link fields in header page (create account, signup), same header place i want to add chat link in header top, suggest me how to do this.
First of all, go to your custom theme app/desing/frontend/{Vendor}/{theme}/Magento_Theme/layout/default.xml
file.
There you will find the below with the links you mentioned, just add the part below for your chat
<referenceContainer name="header.panel">
<block class="Magento\Framework\View\Element\Html\Links" name="top.links">
....
<block class="Magento\Framework\View\Element\Html\Link\Current" name="my-link1">
<arguments>
<argument name="label" xsi:type="string" translate="true">Chat</argument>
<argument name="path" xsi:type="string">Your_Link_To_The_Chat</argument>
</arguments>
</block>
</block>
</referenceContainer>