Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Minor fixes

  • Loading branch information...
commit c4e64366c758e08a77f4cb2ce767e96c9313bee8 1 parent b7abee1
@mehlah mehlah authored
2  action/Controller.php
@@ -201,7 +201,7 @@ public function __invoke($request, $dispatchParams, array $options = array()) {
* This method is used to pass along any data from the controller to the view and layout
- * @param array $data sets of `'variable name' => 'variable value'` to pass to view layer.
+ * @param array $data sets of `<variable name> => <variable value>` to pass to view layer.
* @return void
public function set($data = array()) {
2  template/helper/Html.php
@@ -125,7 +125,7 @@ public function charset($encoding = null) {
* If `$url` is empty, `$title` is used in its place.
* @param string $title The content to be wrapped by an `<a />` tag,
- * or the `title` attribute of a meta-link `<link />`.
+ * or the `title` attribute of a meta-link `<link />`.
* @param mixed $url Can be a string representing a URL relative to the base of your Lithium
* application, an external URL (starts with `'http://'` or `'https://'`), an
* anchor name starting with `'#'` (i.e. `'#top'`), or an array defining a set
10 template/
@@ -2,7 +2,7 @@
Views have a special syntax for outputting escaped text. The standard way to
output escaped text in your views from Lithium is as follows: {{{
-<?= $variable; ?>
+<?=$variable; ?>
This is where a lot of confusion comes in, because it is commonly misunderstood
@@ -22,16 +22,16 @@ familiar syntax and it helps developers focus more on what data _should not_ be
escaped vs. what data _needs_ to be escaped.
One special case situation to take _important_ note of, is the use of
-`<?= $this->foo() ?>`. In this scenario, the code is translated to
+`<?=$this->foo(); ?>`. In this scenario, the code is translated to
`<?php echo $this->foo(); ?>` rather than being filtered through `$h()` as with
the former explanation. When direct access to a method or property on `$this` is
contained in the shorthands syntax, it will be output as normal without being
filtered. This is to make it easier to work with helpers that return markup.
An example would be something like: {{{
-<?= $this->form->create(); ?>
+<?=$this->form->create(); ?>
... my form here ...
-<?= $this->form->end(); ?>
+<?=$this->form->end(); ?>
**Note:** `$h()` is the HTML escape function used in views.
@@ -88,7 +88,7 @@ class Custom extends \lithium\template\Helper {
You can then use your helper in templates as follows:
-<?= $this->custom->greeting('World'); ?>
+<?=$this->custom->greeting('World'); ?>
Your custom helper will then be auto-loaded into the templating engine from your application or a
Please sign in to comment.
Something went wrong with that request. Please try again.