render a view in a module from ANOTHER module view ?

hello, it’s easy to use classes from an module in another module.

but can we acces direct view files to render them?

for example, 2 modules, [i]contents /i and content_text (specific) :

in content module /views/list/list_contents view must render

content_text module /views/display[i]/_display_text view


in list_contents (contents module) I use


it works for call a class in content_text


$this->renderPartial(‘/display/_display_text’, array())

doesnt work (I tried different paths)

so how can I render content_text module/_display_text in contents module/list_contents?

think in advance :)

How about this:


it works good :)

think GStar!

What about creating a widget?

If you have to render the same view in 2 points, maybe you will reuse even more. Maybe you can generalize a bit more and create a widget even for future.

hello zaccaria, yes you are right, that’s what I did after, build widgets on it