1

enter image description here

I want to add footer link like I attach image . I am using magento2.1

3 Answers 3

1

in admin go to Content->Blocks and there you will find footer_links cms block. You can edit footer_links cms block and add layout / html of your footer.

or create a cms block with any name i.e my_custom_footer and call this in your theme layout ( Magento_Theme/layout/default.xml ) footer section like :

<block class="Magento\Cms\Block\Block" name="footer-socialmedia-link" after="-">
  <arguments>
      <argument name="block_id" xsi:type="string">my_custom_footer</argument>
  </arguments>
</block>
1
  • I think it’s worth mentioning that in a clean Magento install, there are no blocks in the CMS whatsoever.
    – ACJ
    Aug 12, 2019 at 9:42
0

Add extra link

app/design/frontend/{Vendor}/{theme}/Magento_Theme/layout/default.xml

<referenceBlock name="footer_links">
    <block class="Magento\Framework\View\Element\Html\Link\Current" name="custom-link-1">
        <arguments>
            <argument name="label" xsi:type="string">My new footer title</argument>
            <argument name="path" xsi:type="string">path-link</argument>
        </arguments>
    </block>
</referenceBlock>

Add block to you footer

If you want to add different links with Titles etc, you have to create a new phtml then add your links with <ul> <li> etc...

app/design/frontend/{Vendor}/{theme}/Magento_Theme/layout/default.xml

<referenceContainer name="footer-container">
    <container name="my-new-footer" as="footer.new" label="Page new Footer" htmlTag="div" htmlClass="footer content">
        <block class="Magento\Framework\View\Element\Template" name="custom-footer" template="html/custom-footer.phtml" />
    </container>
</referenceContainer>

app/design/frontend/{Vendor}/{theme}/Magento_Theme/templates/html/custom-footer.phtml

Footer content here
0

To add footer links in your Magento 2 store, create a layout file default.xml. Let's suppose you have to add Create account link, for that here's a code:

<?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="footer_links">
         <block class="Magento\Framework\View\Element\Html\Link\Current" name="custom-footer-link">
             <arguments>
                 <argument name="label" xsi:type="string">Create Account</argument>
                 <argument name="path" xsi:type="string">customer/account/create/</argument>
             </arguments>
         </block>
     </referenceBlock>
</body>
</page>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.