[Templates] "calculated" path to template
Jason Gottshall
jgottshall@capwiz.com
Thu, 2 Feb 2006 13:27:34 -0500
As long as Template::Provider is being patched for a new release, is
there any chance of adding an additional piece of info to the
template/component hash? I've encountered situations, when I'm using a
list of INCLUDE_PATHs, where it would be useful to have access to the
calculated full path to the actual template file.
=20
If I'm not mistaken, this would only require a one-line addition to the
_compile() method. I haven't done much patching, so forgive me if this
isn't correctly formatted:
=20
--- Template/Provider.pm 2004-01-30 13:37:50.000000000 -0500
+++ Provider.pm 2006-02-02 13:19:59.000000000 -0500
@@ -839,6 +839,7 @@
$parsedoc->{ METADATA } =3D {
'name' =3D> $data->{ name },
'modtime' =3D> $data->{ time },
+ 'path' =3D> $data->{ path },
%{ $parsedoc->{ METADATA } },
};
The key name "path" is merely a suggestion, but I hope the concept makes
sense. Comments, anyone?
Jason
Jason Gottshall
jgottshall@capitoladvantage.com=20