I would like to add payment logo in my footer, and also to add a facebook block in my footer. Exist it an extension?
2 Answers
Good way of adding payment logo and social icon in footer ,so that admin can easily change these images:
- Create a static block from admin and add image there.
- Call that static block in your footer.phtml located at:
app/design/frontend/your_package/your_template/template/page/html
- You can call static block by using below code:
$this->getLayout()->createBlock('cms/block')->setBlockId('block_id')->toHtml();
Replace block_id with your static block id.
-
In the footer.phtml It is necessary to add the code $this-> getLayout()-> createBlock('cms/block')-> setBlockId ('block_id')-> toHtml(); Apr 30, 2015 at 19:22
-
Yes, if you want to call your static block in footer then you have to call in this way. In this way you can change payment logo and other images in footer from admin whenever you want. Apr 30, 2015 at 19:23
-
<?php /* <?php if ($tmp = $this->getChildHtml('block_footer_payment')): ?> <div class="item float-right block_footer_payment"><?php echo $tmp; ?></div> <?php endif; ?> <?php if ($tmp = $this->getChildHtml('store_switcher')): ?> <div class="item float-right"><?php echo $tmp; ?></div> <?php endif; ?> */ ?> Apr 30, 2015 at 20:25
-
I find this code in my footer.phtml and block static was already create. I remove the comments but it does not display my means of payment Apr 30, 2015 at 20:26
-
There isn't any static block calling in your code , that's actually calling of child phtml file. Please use my suggestion of calling static block, this will be a good way of putting icons and images in footer. May 1, 2015 at 6:30
Hi cam do this easy at some code;
first out images at skin/frontend/YOUR Package/Your Template/images/
Then Goto app/design/frontend/YOUR Package/Your Template/template/page/html
and open footer.phtml
Call this images using code:
<?php echo $this->getSkinUrl('images/yourimagename.imageextension') ;>