Differences

This shows you the differences between two versions of the page.

upgrading [2009/09/18 16:54]
Kornel
upgrading [2014/03/19 00:35] (current)
2001:8b0:1151:da70:d5a5:342d:5866:d59e 13
Line 1: Line 1:
====== Upgrading from older releases ====== ====== Upgrading from older releases ======
-These are only changes that could affect existing templates. You'll find all those instructions and additional information about changes/features in [[http://phptal.org/|release annoucements]].+These are only changes that could affect existing templates/installations. You'll find all those instructions and additional information about changes/features in [[http://phptal.org/|release annoucements]]
 + 
 +===== 1.2.2 → 1.3.0 ===== 
 + 
 +''metal:fill-slot'' used outside ''metal:use-macro'' is no longer supported (it used to magically pre-fill slots for later use). Make sure you're using slots as described in the manual. 
 + 
 +Removed support for custom code generators using the old ''PHPTAL_Php_Tree'' interface. 
 + 
 +===== 1.2.0 → 1.2.2 ===== 
 + 
 +You don't need to ''include''/''require'' files other than ''PHPTAL.php''. You can remove any superfluous ''require''s.  
 + 
 +In case autoloading causes any problems and/or you want to use your own autoloader //instead of// PHPTAL's built-in one, execute this after loading ''PHPTAL.php'': 
 + 
 +   spl_autoload_unregister(array('PHPTAL','autoload')); // ugly workaround 
 + 
 +and then call ''PHPTAL::autoload()'' from your autoloader.
===== 1.1.14 → 1.2.0 ===== ===== 1.1.14 → 1.2.0 =====
 +
 +You can automatically find most incompatible templates using the [[lint|lint tool]].
==== Entities and encodings ==== ==== Entities and encodings ====
Line 27: Line 45:
==== XML ==== ==== XML ====
- 
  * XML namespace of ''phptal:*'' attributes has changed from ''%%http://xml.zope.org/namespaces/phptal%%'' to ''%%http://phptal.org/ns/phptal%%''.   * XML namespace of ''phptal:*'' attributes has changed from ''%%http://xml.zope.org/namespaces/phptal%%'' to ''%%http://phptal.org/ns/phptal%%''.
- 
  * Comments are required to be well-formed (''%%--%%'' is not allowed in comments.) Comments starting with ''%%<!--!%%'' are stripped from output.   * Comments are required to be well-formed (''%%--%%'' is not allowed in comments.) Comments starting with ''%%<!--!%%'' are stripped from output.
 +  * Duplicate attributes are not allowed and they must be separated with space. ''<b title=""title="">'' is doubly wrong.
-==== Last, but not least ==== +==== Other issues ====
 +  * use ''| nothing'' instead of ''| false'' to avoid getting zeros (''false'' is now printed as ''0'').
  * ''tal:repeat'' doesn't “leak” variables to outer scope   * ''tal:repeat'' doesn't “leak” variables to outer scope
  * Internal DOM classes have been refactored. Your **custom TAL attributes could break** -- if they did, please complain on the mailinglist!   * Internal DOM classes have been refactored. Your **custom TAL attributes could break** -- if they did, please complain on the mailinglist!
Line 41: Line 58:
===== 1.1.x → 1.1.14 ===== ===== 1.1.x → 1.1.14 =====
-In 1.1.13 translation key like ''%%<p i18n:translate="'żółw'" />%%'' was interpreted as ''%%<p i18n:translate="'<C197><C188><C195><C179><C197><C130>w'">%%'' and you had to use ''msgid "<C197><C188><C195><C179><C197><C130>w"'' in your ''.po'' files.+In 1.1.13 translation key like ''%%<p i18n:translate="'żółw'" />%%'' was interpreted as ''%%<p i18n:translate="'<C197><C188><C195>­<C179><C197><C130>w'">%%'' and you had to use ''msgid "<C197><C188><C195>­<C179><C197><C130>w"'' in your ''.po'' files.
PHPTAL 1.1.14 stops doing this and keys are now left unchanged. The example above would simply expect ''msgid "żółw"'' in the ''.po'' file. PHPTAL 1.1.14 stops doing this and keys are now left unchanged. The example above would simply expect ''msgid "żółw"'' in the ''.po'' file.