Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

How do i add an outside link to callout block images. 
 
Anita
Jr. Member
 
Total Posts:  1
Joined:  2008-03-09
Idaho
 

I like to add an outside link in one of my right callout blocks. Do I use the core or cms xml or phtml files. Should this be done in the xml files or phtml file. I do not know the code to add it to a new or old callout block. Can someone help! Also where and what code do I use for adding a in site link, some where like the about us page.

Anita

Image Attachments
Picture-1.jpg
 
Magento Community Magento Community
Magento Community
Magento Community
 
JamieD
Jr. Member
 
Total Posts:  30
Joined:  2009-09-08
 

I am no expert, but I found this on another thread and it helped me. Go to app/design/frontend/default/yourtheme/layout/catalog.xml
You should be able to find the code that corresponds to your existing callout image.  Insert any part of the code below that is missing.  Most likely the <action method="setLinkUrl"><url>website-url</url></action> line

<reference name="right">
            <!--    <
block type="core/template" name="right.permanent.callout" template="callouts/right_col.phtml"/>    -->
            <
block type="core/template" name="left.permanent.callout" template="callouts/left_col.phtml">
                <
action method="setImgSrc"><src>images/media/promotions/yourimage.gif</src></action>
                <
action method="setImgAlt" translate="alt" module="catalog"><alt>Alternate text Here</alt></action>
                <
action method="setLinkUrl"><url>website-url</url></action
            </
block>
</
reference>

to link to an outside website put in the whole url for example http://www.yourotherwebsite.com
to link to a page inside of magento you can just put in the page name.  For example checkout/cart will take you to the shopping cart.
hope this helps.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top