0

I have a problem with my theme: The error message is not at the top of the page. See error message at bottom of page

It should be like this:

enter image description here

Now the real problem: For my test environment I already found a solution, by changing the order of following code in 2columns-left.phtml from

<?php echo $this->getChildHtml('breadcrumbs') ?>
<?php echo $this->getChildHtml('index_block') ?>
<?php echo $this->getChildHtml('global_messages') ?>                                        
<?php echo $this->getChildHtml('content') ?>    

TO

<?php echo $this->getChildHtml('breadcrumbs') ?>
<?php echo $this->getChildHtml('global_messages') ?>                                        
<?php echo $this->getChildHtml('index_block') ?>
<?php echo $this->getChildHtml('content') ?>

But in my live environment, there is no change! I already flushed cache, reindexed and compared the both installations (no differences in files). Compiler is not active.

The block above the error message in first pic is the cms_block "index_block".

Any ideas?

  • in which file you have changed add you file path – Prashant Valanda Apr 22 '16 at 6:49
  • It was \app\design\frontend\default\theme259k\template\page\2columns-left.phtml. But I found a solution will post it immediately – Jonathan Apr 22 '16 at 6:58
0

Found workaround, can't tell why I didn't think of it in first place.

In my cms-page "home" I changed:

<block type="cms/block" name="index_block">
    <action method="setBlockId"><block_id>index_block</block_id></action>
</block>

To

<block type="cms/block" name="index_block" after="global_messages">
    <action method="setBlockId"><block_id>index_block</block_id></action>
</block>

Seems like index_block in 2columns-left.phtml is not the same as the cms-block?!

Still don't know why the change of code worked in test but not in live, but with this solution everything works fine.

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.