2009年10月1日星期四

[fw-mvc] Resetting a Placeholder?

I have a widget on each page rendered into a View's placeholder by a pre-dispatch plugin.  There are a very few pages where I don't want to see it.

Is there a way to actively wipe out that placeholder in the controller rather than test for those pages all the time? Placeholder method set() doesn't seem to do it, though append() and prepend() work as I expect.

Creating the widget does work that would otherwise happen elsewhere, so I don't really care if it builds or not.  But with only two or three URLs where it's not wanted, I don't want to overhead of a test on the other 99% of pages.

Tim Stiles,
Co-Organizer of DallasPHP
monkeyt@DallasPHP.org

没有评论: