So I setup Fishpigs WordPress extension about a month ago on my Magento site and all was working well. Somewhere, somehow in the last week the formatting went haywire. Tracking down what went wrong, I found that the post pages stopped using my custom .phtml layout (‘wordpress.phtml’). All other wordpress related pages use the template properly though.
I had added
<wordpress_default>
<reference name="root">
<action method="setTemplate"><template>page/wordpress.phtml</template></action>
</reference>
</wordpress_default>
in my local.xml and all was good. Today I even tried setting all the layouts in the extension settings and same deal, only the post page isn’t rendering the correct layout. This is a strange problem, I’m not sure where to start looking…
I see three possibilities here (assuming you’ve already performed the holy rite of clearing your cache storage)
The request for the post page isn’t loading your
local.xmlfile, possibly because its using a different theme and/or design packageThe post page isn’t issuing the
wordpress_defaulthandle, so although yourlocal.xmlfile is being included, yoursetTemplateaction is never calledThere is a layout update that’s called after your layout update (either via XML or directly in PHP code) which sets the root template to something else.
Investigate each of these three items and you should find your answer.
Regarding choice #3, I don’t have an installation with the FishPig extension installed and haven’t used it extensively, but it looks like the extension does some jiggery pokery in
ViewController.phpto automatically set the template topage/1column.phtmlif the wordpress page object (? I don’t know what this is) has a field set to'onecolumn'or'1column'.I’d start looking there.