]> git.pld-linux.org Git - packages/php-pear-HTML_Template_Flexy.git/blob - php-pear-HTML_Template_Flexy.spec
- en fixes and formatting
[packages/php-pear-HTML_Template_Flexy.git] / php-pear-HTML_Template_Flexy.spec
1 %include        /usr/lib/rpm/macros.php
2 %define         _class          HTML
3 %define         _subclass       Template
4 %define         _status         stable
5 %define         _pearname       %{_class}_%{_subclass}_Flexy
6
7 Summary:        %{_pearname} - a flexible caching template engine based on SimpleTemplate
8 Summary(pl):    %{_pearname} - elastyczny buforuj±cy silnik szablonów oparty na SimpleTemplate
9 Name:           php-pear-%{_pearname}
10 Version:        1.1.1
11 Release:        2
12 License:        PHP 2.02
13 Group:          Development/Languages/PHP
14 Source0:        http://pear.php.net/get/%{_pearname}-%{version}.tgz
15 # Source0-md5:  325a6993dd88c2fc99badf2170043e53
16 Patch0:         %{name}-case_fix.patch
17 Patch1:         %{name}-path_fix.patch
18 URL:            http://pear.php.net/package/HTML_Template_Flexy/
19 BuildRequires:  rpm-php-pearprov >= 4.0.2-98
20 Requires:       php-pear
21 BuildArch:      noarch
22 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24 %description
25 HTML_Template_Flexy started it's life as a simplification of
26 HTML_Template_Xipe, however in version 0.2, it became one of the first
27 template engine to use a real Lexer, rather than regexes, making it
28 possible to do things like ASP.net or Cold Fusion tags. However, it
29 still has a very simple set of goals.
30 - Very Simple API,
31         - easy to learn...
32         - prevents to much logic going in templates
33 - Easy to write documentable code
34         - By using object vars for a template rather than 'assign',
35           you can use PHPDoc comments to list what variable you use.
36 - Editable in WYSIWYG editors
37         - you can create full featured templates, that doesnt get
38           broken every time you edit with Dreamweaver(tm) or Mozilla
39           editor
40         - Uses namespaced attributes to add looping/conditionals
41 - Extremely Fast
42         - runtime is at least 4 time smaller than most other template
43           engines (eg. Smarty)
44         - uses compiled templates, as a result it is many times faster
45           on blocks and loops than than Regex templates (eg.
46           IT/phplib)
47 - Safer (for cross site scripting attacks)
48         - All variables default to be output as HTML escaped
49           (overridden with the :h modifier)
50 - Multilanguage support
51         - Parses strings out of template, so you can build translation
52           tools
53         - Compiles language specific templates (so translation is only
54           done once, not on every request)
55 - Full dynamic element support (like ASP.NET), so you can pick
56           elements to replace at runtime
57
58 Features:
59 - {variable} to echo $object->variable
60 - {method()} to echo $object->method();
61 - {foreach:var,key,value} to PHP foreach loops
62 - tag attributes FLEXY:FOREACH, FLEXY:IF for looping and conditional
63   HTML inclusion
64 - {if:variable} to PHP If statement
65 - {if:method()} to PHP If statement
66 - {else:} and {end:} to close or alternate If statements
67 - FORM to HTML_Template_Flexy_Element's
68 - replacement of INPUT, TEXTAREA and SELECT tags with
69   HTML_Template_Flexy_Element code use FLEXY:IGNORE (inherited) and
70   FLEXY:IGNOREONLY (single) to prevent replacements
71 - FLEXY:START/FLEXY:STARTCHILDREN tags to define where template
72   starts/finishes
73 - support for urlencoded braces {} in HTML attributes.
74 - documentation in the pear manual
75
76 - examples at
77   http://cvs.php.net/cvs.php/pear/HTML_Template_Flexy/tests/
78
79 The long term plan for Flexy is to be integrated as a backend for the
80 Future Template Package (A BC wrapper will be made available - as I
81 need to use it too!)
82
83 In PEAR status of this package is: %{_status}.
84
85 %description -l pl
86 Flexy Template to silnik szablonów do konwertera kodu PHP, oparty na
87 Simple Template i podobny do Smarty. Powinien byæ bardzo szybki, jest
88 ³atwy w rozszerzaniu, rozwijaniu i u¿ywaniu dowolnej sk³adni
89 szablonów. Domy¶lny filtr (SimpleTags) zawiera: zmienne, pêtle
90 foreach, warunki, wywo³ania metod, w³±czanie kodu, obs³uguje znaczniki
91 zakodowane w URL-ach - wiêc mo¿e modyfikowaæ szablony w Mozilli itp.
92 Inne filtry to:
93 - RtfSimpletags - do tworzenia dokumentów RTF dla Worda,
94 - BodyOnly - wycinaj±cy nag³ówek i stopkê z szablonu,
95 - Php - wycinaj±cy kod PHP z szablonu,
96 - Email - do przetwarzania szablonów e-mail.
97
98 Ta klasa ma w PEAR status: %{_status}.
99
100 %prep
101 %setup -q -c
102 cd %{_pearname}-%{version}
103 %patch0 -p1
104 %patch1 -p1
105
106 %install
107 rm -rf $RPM_BUILD_ROOT
108 install -d $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/{Compiler/{Flexy,Standard,Regex},Element,Plugin,Token}
109         
110 install %{_pearname}-%{version}/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}
111 install %{_pearname}-%{version}/Flexy/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy
112 install %{_pearname}-%{version}/Flexy/Compiler/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/Compiler
113 install %{_pearname}-%{version}/Flexy/Compiler/Flexy/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/Compiler/Flexy
114 install %{_pearname}-%{version}/Flexy/Compiler/Standard/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/Compiler/Standard
115 install %{_pearname}-%{version}/Flexy/Compiler/Regex/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/Compiler/Regex
116 install %{_pearname}-%{version}/Flexy/Element/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/Element
117 install %{_pearname}-%{version}/Flexy/Plugin/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/Plugin
118 install %{_pearname}-%{version}/Flexy/Token/*.php $RPM_BUILD_ROOT%{php_pear_dir}/%{_class}/%{_subclass}/Flexy/Token
119
120 %clean
121 rm -rf $RPM_BUILD_ROOT
122
123 %files
124 %defattr(644,root,root,755)
125 %doc %{_pearname}-%{version}/{Flexy/example.ini,tests}
126 %{php_pear_dir}/%{_class}/%{_subclass}/Flexy
127 %{php_pear_dir}/%{_class}/%{_subclass}/Flexy.php
This page took 0.090404 seconds and 4 git commands to generate.