Magento Forum

Page 1 of 2
Removing callouts like polls, newsletter. Adding front-page specific items? 
 
andrewmaier
Jr. Member
 
Avatar
Total Posts:  22
Joined:  2008-01-13
 

Hello,

I’d like to go about removing the poll/newsletter/stock images, from my left/right columns. In addition, I’d like to add specific items to the frontpage, like recently added items, and popular categories. CAn someone instruct me how to do so? I’ve tried searching the forums, to no avail :(

-Andrew

 
Magento Community Magento Community
Magento Community
Magento Community
 
andrewmaier
Jr. Member
 
Avatar
Total Posts:  22
Joined:  2008-01-13
 

*bump*

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

to remove poll go to poll.xml select all the code and simply apply html comments code like this

<!--
Default layout, loads most of the pages
-->

around the code EG

<default>

        <!-- 
Mage_Poll -->

       <!--  <
reference name="right">
            <
block type="poll/activePoll" name="right.poll">
                <
action method="setPollTemplate"><template>poll/active.phtml</template><type>poll</type></action>
                <
action method="setPollTemplate"><template>poll/result.phtml</template><type>results</type></action>
            </
block>
        </
reference>-->

    </default>

Call outs

go to catalog.xml

find this code

<reference name="left">
            <
block type="core/template" name="left.permanent.callout" template="callouts/left_col.phtml">
                <
action method="setImgSrc"><src>images/media/col_left_callout.jpg</src></action>
                <
action method="setImgAlt"><alt>Our customer service is available 24/7. Call us at (800DEMO-NUMBER.</alt></action>
                <
action method="setLinkUrl"><url>checkout/cart</url></action>
                <
action method="setLinkUrl"><url>http://www.greenstone.maori.nz/</url></action>
            
</block>
        </
reference>
        <
reference name="left">
            <
block type="core/template" name="catalog.compare.sidebar" template="catalog/product/compare/sidebar.phtml"/>
            <
block type="core/template" name="right.permanent.callout" template="callouts/right_col.phtml"/>
        </
reference>

and comment out the code that calls the callout images

or change the images in that folder to reflect yours

Kind regards
Bill007 http://www.euphorish.com Web design freebees

 
Magento Community Magento Community
Magento Community
Magento Community
 
harry12bar
Sr. Member
 
Avatar
Total Posts:  168
Joined:  2008-01-07
 

Home page specific controls, middle section can be controlled from CMS in admin… put in what you want for home page only.
Cheers

 
Magento Community Magento Community
Magento Community
Magento Community
 
andrewmaier
Jr. Member
 
Avatar
Total Posts:  22
Joined:  2008-01-13
 

:thinks:

Okay, so what I want to do is add a div for recently added items ABOVE the content div. From what I gather, I can only add things to the content div via the middle section of the CMS Home Page screen. Maybe something to do with updating the xml at the bottom?

-A

 
Magento Community Magento Community
Magento Community
Magento Community
 
andrewmaier
Jr. Member
 
Avatar
Total Posts:  22
Joined:  2008-01-13
 

Okay, so I’m trying to add a div above my content, below my header: I went about editing my page.xml, adding

<block type="page/html" name="catchLinks" as="catchLinks"/>

***
Right before***

 <
block type="page/html_breadcrumbs" name="breadcrumbs" as="breadcrumbs"/>

then, in my CMS > Home Page, I updated the layout by:

<reference name="catchLinks">
    <
block type="page/html" name="default_catchLinks" template="callouts/default_catchLinks.phtml"/>
</
reference>

Obviously, I added a default_catchLinks.phtml in the appropriate directory:

which basically has the following until it actually works:

<h1>I'm your awesome farking catchLinks</h1>

But nothing’s showing up. Any idea?

 
Magento Community Magento Community
Magento Community
Magento Community
 
cpi81
Jr. Member
 
Total Posts:  4
Joined:  2009-02-02
 

Poll… the easiest way wouldn’t be just to set the poll status to Closed?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Cheung
Jr. Member
 
Avatar
Total Posts:  30
Joined:  2008-10-09
Seattle, WA
 

Easiest way to disable polls is from the Admin.

System/Configuration/Advanced/Advanced

and disable Mage_Poll

 
Magento Community Magento Community
Magento Community
Magento Community
 
thegwin
Jr. Member
 
Total Posts:  11
Joined:  2009-05-02
Japan
 

This is how I successfully got rid of the left and right column default pics in Magento ver. 1.2.1.2

HOW TO REMOVE col_left_callout.jpg

1. Open app/design/frontend/default/default/layout/catalog.xml
2. Search for col_left_callout (default line 53)
3. Remove all of the following code:

<reference name="left">
            <
block type="core/template" name="left.permanent.callout" template="callouts/left_col.phtml">
                <
action method="setImgSrc"><src>images/media/col_left_callout.jpg</src></action>
                <
action method="setImgAlt" translate="alt" module="catalog"><alt>Our customer service is available 24/7. Call us at (800DEMO-NUMBER.</alt></action>
                <
action method="setLinkUrl"><url>checkout/cart</url></action>
            </
block>
        </
reference>


HOW TO REMOVE col_right_callout.jpg

1. Open app/design/frontend/default/default/template/callouts/right_col.phtml
2. Remove all of the following code:

<div class="box">
    <
img src="<?php  echo $this->getSkinUrl('images/media/col_right_callout.jpg') ?>" width="195" alt="<?php echo __('Keep your eyes open for our special Back to School items and save A LOT!') ?>" style="display:block;" />
</
div>

That’s it! Whether this is the correct/best way to do this, I don’t know but it’s working OK for me.

NOTE: This works fine if you don’t wish to replace the images with ones of your own, i.e. are happy to just delete them completely.

Don’t forget to back up all files before changing and don’t forget to substitute your theme name in the file paths above, i.e.

app/design/frontend/YOUR_INTERFACE_NAME/YOUR_THEME_NAME/layout/catalog.xml
app/design/frontend/YOUR_INTERFACE_NAME/YOUR_THEME_NAME/template/callouts/right_col.phtm

 
Magento Community Magento Community
Magento Community
Magento Community
 
Diana38
Jr. Member
 
Total Posts:  13
Joined:  2009-02-18
 

Thank you so much for that post ..very useful.

 
Magento Community Magento Community
Magento Community
Magento Community
 
myktux
Jr. Member
 
Total Posts:  3
Joined:  2009-05-15
 

Another simpler way is:

1) Go to Manage Pages
2) Choose the landing page you want to remove it
3) Go to Custom design and add the following tags:

<reference name="right">
  <
action method="unsetChild"><name>right.permanent.callout</name></action>
</
reference>

Done!

 
Magento Community Magento Community
Magento Community
Magento Community
 
thegwin
Jr. Member
 
Total Posts:  11
Joined:  2009-05-02
Japan
 

Ignore my method! myktux method is the way to go. Many thanks for that insight.

And to remove callouts from the category pages, just navigate to the category of your choice, click custom design and add the same code.

To remove a callout from the LEFT colum, just substitute the word right with left in the code above (two instances), i.e.

<reference name="left">
  <
action method="unsetChild"><name>left.permanent.callout</name></action>
</
reference>

 
Magento Community Magento Community
Magento Community
Magento Community
 
thegwin
Jr. Member
 
Total Posts:  11
Joined:  2009-05-02
Japan
 

Actually, on reflection, if you’re intention is to PERMANENTLY remove the callouts then my first method is probably the simplest and least time-consuming!

 
Magento Community Magento Community
Magento Community
Magento Community
 
developer0
Jr. Member
 
Total Posts:  6
Joined:  2009-07-01
 

The correct way to remove a callout from a page is to add the following (example) to the Update Layout section of page management in the admin:

<remove name="right.permanent.callout"/>

You can find the name to remove in the layout .xml file.

 
Magento Community Magento Community
Magento Community
Magento Community
 
developer0
Jr. Member
 
Total Posts:  6
Joined:  2009-07-01
 

...also…
You can also add these ‘name removals’ in the category section for category pages under Custom Layout Update (no need to put in <default>)

You can also add these to the layout xml files. Add in <default> where you would add a reference. I’ve done this to remove the callouts from the contacts page.

Here’s some examples:

<remove name="right.poll"/>
<remove name="tags_popular"/>
<remove name="catalog.compare.sidebar"/>
<remove name="right.reports.product.viewed"/>
<remove name="right.permanent.callout"/>
<remove name="sale.reorder.sidebar"/>
<remove name="wishlist_sidebar"/>

 
Magento Community Magento Community
Magento Community
Magento Community
 
developer0
Jr. Member
 
Total Posts:  6
Joined:  2009-07-01
 

..er SORRY - SCRAP THE ABOVE:

There can be simple xml element add attribute errors.

http://activecodeline.com/warning-simplexmlelementaddattribute-simplexmlelementaddattribute-attribute-already-exists/

Changes I make to contacts.xml effect the entire site - not just the contact page so there’s conflict between the different NAME removals.

I’ll try to update more when I understand it better. I think it’s OK if you leave the .xml layout files alone. Then again, I thought I had tested it.....

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top
Page 1 of 2