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

are callout boxes this complex or am I missing something? Perhaps this is a feature request? 
 
mk2dev
Member
 
Total Posts:  42
Joined:  2008-08-07
Chicago, IL
 

On the first site we deployed with magento, the customer doesn’t want to ever use the callout boxes, so we pulled them all out, no problem.

The current project we are working on, the client is not using the callout boxes currently, but would like to use them in the future for promotions, etc (as I would imagine they were intended).

It would seem to me that callout boxes should be handled like CMS static blocks, in that you can edit them in some admin and turn them off or on as needed. It seems kinda obtuse to require the developer to get all messy adding them here and there to implement them. From my understanding the only way to implement them is to make the callout image/text, and put it in both the templates and layouts?

Am I missing something? Is it really that complex?

Or is this really a feature request?

 
Magento Community Magento Community
Magento Community
Magento Community
 
joyously
Guru
 
Total Posts:  447
Joined:  2008-08-21
 

It seems to be that complex. I don’t know why.
Couldn’t you just pull them out and recreate them as static blocks? Then they are easily accessible from the backend.

 
Magento Community Magento Community
Magento Community
Magento Community
 
mk2dev
Member
 
Total Posts:  42
Joined:  2008-08-07
Chicago, IL
 

you could just make them static blocks, but then you still have to put them into the layouts and whatnot. which isn’t hard really, but I just wanted to be sure that I wasn’t missing anything....

 
Magento Community Magento Community
Magento Community
Magento Community
 
joyously
Guru
 
Total Posts:  447
Joined:  2008-08-21
 

I got my head wrapped around how to do this now. It’s not that complicated and it didn’t even break when the static block did not exist.
In the default theme, the catalog.xml file has this for the left callout:

<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>
I changed it to this:
<reference name="left">
      <
block type="cms/block" name="left.permanent.callout">
          <
action method="setBlockId"><block_id>left_column_block</block_id></action>
      </
block>
  </
reference>
and added a CMS Static Block with an ID of left_column_block. I can put whatever I want in there from the backend(including empty) and it will show in the left column. I did the same thing with the right column, and can add more in strategic places for future editing by the client in the backend.
 
Magento Community Magento Community
Magento Community
Magento Community
 
davidn
Jr. Member
 
Total Posts:  24
Joined:  2008-08-14
 

May I ask what your code for was in the admin section?

 
Magento Community Magento Community
Magento Community
Magento Community
 
joyously
Guru
 
Total Posts:  447
Joined:  2008-08-21
 
davidn - 25 October 2008 07:00 AM

May I ask what your code for was in the admin section?

I don’t understand the question. 
Assuming you are asking me what code I put in the backend for the block, I’d answer like before: you can put anything you want. An image, or text or HTML. I haven’t tried putting a block in a block, so can’t say if that works.

Update: A block in a block does work just fine.
Don’t forget that you need to fix your template to output the content of the block such as calling $this->getChildHtml()

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