Browse code

update Core Extension doc

nikic authored on 23/12/2010 10:26:09 • Fabien Potencier committed on 23/12/2010 11:31:14
Showing 1 changed files
... ...
@@ -224,15 +224,14 @@ is still fresh, given the last modification time, or ``false`` otherwise.
224 224
 Using Extensions
225 225
 ----------------
226 226
 
227
-Twig extensions are packages that adds new features to Twig. Using an
227
+Twig extensions are packages that add new features to Twig. Using an
228 228
 extension is as simple as using the ``addExtension()`` method::
229 229
 
230 230
     $twig->addExtension(new Twig_Extension_Sandbox());
231 231
 
232 232
 Twig comes bundled with the following extensions:
233 233
 
234
-* *Twig_Extension_Core*: Defines all the core features of Twig and is
235
-  automatically registered when you create a new environment.
234
+* *Twig_Extension_Core*: Defines all the core features of Twig.
236 235
 
237 236
 * *Twig_Extension_Escaper*: Adds automatic output-escaping and the possibility
238 237
   to escape/unescape blocks of code.
... ...
@@ -276,15 +275,17 @@ The ``core`` extension defines all the core features of Twig:
276 275
   * ``filter``
277 276
   * ``macro``
278 277
   * ``import``
278
+  * ``from``
279 279
   * ``set``
280
+  * ``spaceless``
280 281
 
281 282
 * Filters:
282 283
 
283 284
   * ``date``
284 285
   * ``format``
285
-  * ``even``
286
-  * ``odd``
287
-  * ``urlencode``
286
+  * ``replace``
287
+  * ``url_encode``
288
+  * ``json_encode``
288 289
   * ``title``
289 290
   * ``capitalize``
290 291
   * ``upper``
... ...
@@ -294,15 +295,29 @@ The ``core`` extension defines all the core features of Twig:
294 295
   * ``reverse``
295 296
   * ``length``
296 297
   * ``sort``
297
-  * ``in``
298
-  * ``range``
299
-  * ``cycle``
298
+  * ``merge``
300 299
   * ``default``
301 300
   * ``keys``
302
-  * ``items``
303 301
   * ``escape``
304 302
   * ``e``
305 303
 
304
+* Functions:
305
+
306
+  * ``range``
307
+  * ``constant``
308
+  * ``cycle``
309
+
310
+* Tests:
311
+
312
+  * ``even``
313
+  * ``odd``
314
+  * ``defined``
315
+  * ``sameas``
316
+  * ``none``
317
+  * ``divisibleby``
318
+  * ``constant``
319
+  * ``empty``
320
+
306 321
 Escaper Extension
307 322
 ~~~~~~~~~~~~~~~~~
308 323