2011-06-20, 15:48:55
tl;dr for Chris:
The proposed solution has the original get_component() code in it. The one big addition is:
This puts all arguments other than the first (which we assume is the component name) in an array $args.
Now the component code can use $args[n] to make use of arguments passed from the template to the get_component function:
The proposed solution has the original get_component() code in it. The one big addition is:
Code:
if (func_num_args() > 1) { $args = func_get_args(); array_shift($args); }
Now the component code can use $args[n] to make use of arguments passed from the template to the get_component function:
Code:
get_component('name','argument0','argument1', …)
“Don’t forget the important ˚ (not °) on the a,†says the Unicode lover.
Help us test a key change for the core! ¶ Problems with GetSimple? Be sure to enable debug mode!
Help us test a key change for the core! ¶ Problems with GetSimple? Be sure to enable debug mode!