I think I need a snippet with parameters.
I see several possible approaches to doing this. It appears there are a
couple of extensions available to do this and I would expect it cold be done
by creating a radius tag for the purpose instead of using a snippet.
However, I have no idea of how to proceed.
Is there a "best practice" for this?
_______________________________________________
Radiant mailing list
Post: Rad...@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site: http://lists.radiantcms.org/mailman/listinfo/radiant
The first is Manuel Meurer's Parameterized Snippets Extension:
http://github.com/manuelmeurer/radiant-parameterized-snippets-extension
Manuel's extension was designed to do exactly what you are asking.
The other solution combination of two extensions that I created -
Variables, and Conditional Tags:
http://github.com/SwankInnovations/radiant-conditional-tags-extension
http://github.com/SwankInnovations/radiant-variables-extension
This is a bit more generic approach. The Variables extension lets you
declare variables for use within a page or pass variables to page parts
and/or snippets (parameters essentially). The Conditional Tags
extension, then allows you to use these variables and perform
conditional evaluations on them. Of course the Conditional Tags aren't
limited to your variables -- you can also use them with page properties
or even build your own evaluators. So it's more of a wider net approach.
Both solutions haven't been updated in some time and may have issues
with the new version of radius tags but probably not. I plan on looking
into updating my extensions here soon.
-Chris