1

I am trying to find the option that how I can edit the link of google plus in header.

I find in CMS > Static block but no success, Please help me, How can I edit or add the link

enter image description here

  • are you using custom theme ? if so, which one ? – Anil Suthar Jul 15 '16 at 9:18
0

Here is how I did it.

I was using my custom theme. Go to folder app/design/frontend/vendor_name/theme_name/Magento_Theme/layout/default.xml

        <referenceContainer name="header-wrapper">
            <container name="custom.header" htmlClass="headerSitemenu" htmlTag="div">
                <block class="Magento\Framework\View\Element\Template" name="social.links" before="-" template="Magento_Theme::social-links.phtml">
                </block>
            </container>
        </referenceContainer>

My custom .phtml file name is social-links.phtml. In this file I have the following code. This file is located at <mage-root>/app/design/frontend/vendor_name/theme_name/Magento_Theme/templates/social-links.phtml

<?php
/**
 * Copyright © 2016 Magento. All rights reserved.
 * See COPYING.txt for license details.
 */

// Social Icons Bar
// custom file added by Cameron Dixon

?>
<?php echo $this->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('header_social_test')->toHtml();?>

So my custom CMS Block name is

"header_social_test"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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