Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

[HELP] Rendering template from helper

Hey, what's up!

I have been trying to render a stand-alone template from my custom helper, here's my code:

(The code has been simplified)

No matter what path I set up for the view object, I always end up with an error message like this: *View '/path/to/view' was not found in any of the views directory

I've tried several things now, including using other methods for rendering (getRender, render, partial), setting up different view directories to the view object (Relative, absolute).

Question is: Is it possible to render a template from a helper? If so, how to do it?

Thanks in advance.

edited Mar '17

Yes it is, you just need to provide correct path. Post your structure, where is this listinghelper etc things. Also you should use getRender or something like this, partial is for other tasks.