Re: Problem with custom resource compiled filenames
Ivo Jansch <[email protected]> Mon, 22 Aug 2005 12:51:11 +0200
| Newsgroups | gmane.comp.php.smarty.devel |
|---|---|
| Message-ID | <[email protected]> |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi
Ivo Jansch wrote:
> Monte, do you know of a correct way to solve this? I'd be happy to
> contribute a fix, just point me to the proper place where to solve this.
It appears, that in _get_auto_filename in Smarty.class.php, this piece
of code:
if(isset($auto_source))
{
// make source name safe for filename
$_filename = urlencode(basename($auto_source));
$_crc32 = sprintf('%08X', crc32($auto_source));
// prepend %% to avoid name conflicts with
// with $params['auto_id'] names
$_crc32 = substr($_crc32, 0, 2) . $_compile_dir_sep .
substr($_crc32, 0, 3) . $_compile_dir_sep . $_crc32;
$_return .= '%%' . $_crc32 . '%%' . $_filename;
}
somehow results in an invalid filename anyway. I'm investigating further..
Greetings,
Ivo
- --
Ivo Jansch <[email protected]>
ibuildings.nl BV - information technology
http://www.ibuildings.nl
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFDCa4f95NUnGFZm9cRAgc9AKCwjIkNhR5HiYR6y/LRy78vIooi6QCeOqeo
OQIoZKSyM5KeyruZVJOmgxc=
=k4EE
-----END PGP SIGNATURE-----
--
Smarty Development Mailing List (http://smarty.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php