The Slim Framework support forum has moved to http://discourse.slimframework.com. This Tender forum is no longer maintained or monitored.

Render with parameters

Enrico Signori's Avatar

Enrico Signori

16 Jun, 2015 07:38 AM

It is possible to render a template, example:
$app->render('account/grouprofile.php');

And give it a parameter? But not to use in the view more like:
urlFor('account.event.profile', {eventname: event.eventname})

So i would render the template with the needed url parameter.
Thanks for your time and reading.

  1. 1 Posted by karossa on 16 Jun, 2015 09:36 AM

    karossa's Avatar

    Hi,

    I think you should use one view file per parameter

  2. Enrico Signori closed this discussion on 16 Jun, 2015 01:25 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac