You can use an include, but it might be better to call $this->render() from
within your view. Using $this->render will allow you to use the view's
script path, unlike include() which uses your include path.

I wouldn't use a partial unless you need a fresh new view instance to work
with.

--
Hector


On Mon, Jan 18, 2010 at 3:41 PM, Dehru <[email protected]> wrote:

> Hello,
>
> I have some view code that I want to get outa the way by moving it into an
> include.  It's not necessarily something I'd put in a partial for re-use by
> other views...but you never know.  Anyway, should I use a simple include
> directive to load it, or should I use $this->render() in the view or should
> I use a partial?
>
> What is the preferred way to do this within the view?
>
> Thank you,
> Dehru
>

Reply via email to