3212 Posts in 847 Topics by 809 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 946 Views |
-
Passing parameters from templates

25 July 2011 at 8:29pm Last edited: 25 July 2011 8:30pm
I have a function
function doStuff($parameter){
...return DataObjectSet;
}When I call in from a template
<% control doStuff(123) %>
....
<% end_control %>It works as expected
But if I try to pass a variable as a parameter like $ID or $Title I get a "No Data Received" error
Is this not possible?
-
Re: Passing parameters from templates

25 July 2011 at 11:42pm Last edited: 25 July 2011 11:43pm
Hi obfuscato,
Due to the template being parsed only once - no.
this is my work around... http://www.silverstripe.org/template-questions/show/13619#post290473
Hope this helps
| 946 Views | ||
|
Page:
1
|
Go to Top |


