Quick links: Content - sections - sub sections
EN

Trace:

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
en:tutorials:minitutorial:1.1.x [2009/01/07 21:04] biboen:tutorials:minitutorial:1.1.x [2009/01/07 21:43] bibo
Line 137: Line 137:
 </code> </code>
  
-What this code means is that **index** action of **default** controller retrieves a @@C@jResponseHtml@@ object through the @@M@getResponse()@@ method by passing "html" as argument. And at the endit returns this response indicating that its content must be returned to the browser.+What this code means is that **index** action of **default** controller retrieves a @@C@jResponseHtml@@ object through the @@M@getResponse()@@ method by passing "html" as argument. After processingthe action returns this response thus indicating that its content must be returned to the browser.
  
  
 @@C@jResponseHtml@@ has a @@P@body@@ property, which is a @@C@jTpl@@ object. jTpl is a template engine provided by Jelix.  @@C@jResponseHtml@@ has a @@P@body@@ property, which is a @@C@jTpl@@ object. jTpl is a template engine provided by Jelix. 
-In the action code above, you see a call @@C@assignZone()@@ method. This means : get the content of the 'check_install' zone which is stored in the 'jelix' module, and assign this content to the template variable named @@V@MAIN@@ (You will see what is a zone in details later). 'Check_install' is a zone which shows results of install checkings. If those results are ok, you don't need it anymore. delete this line so you will have this in your controller:+ 
 +In the action code above, you see a call to @@C@assignZone()@@ method. This means : get the content of the 'check_install' zone which is stored in the 'jelix' module, and assign this content to the template variable named @@V@MAIN@@ (You will see what is a zone in details later). 'Check_install' is a zone which shows results of install checkings. If those results are ok, you don't need it anymore. delete this line so you will have this in your controller:
  
 <code php> <code php>
Line 156: Line 157:
 ==== Response object ==== ==== Response object ====
  
-The @@C@jResponseHtml@@ object generates HTML response (HTML page). It generates automatically the @@<head>@@ part of HTML, from some of its properties. Let's define the title of the page. Add this in the @@M@index()@@ method, before the return:+@@C@jResponseHtml@@ object generates an HTML response (an HTML page). It automatically generates the @@<head>@@ part of HTML, from some of its properties.  
 + 
 +Let's define the title of the page. Add this in the @@M@index()@@ method, just before returning the response object :
  
 <code php> <code php>
Line 162: Line 165:
 </code> </code>
  
-Reload the page. The title of the page is now display in your browser title bar. But the page contains this:+Reload the page. The page title should now correctly display in your browser title bar. But still your page contains this:
  
 {{en:tutorials:minitutorial:minituto_1_en.png}} {{en:tutorials:minitutorial:minituto_1_en.png}}

en/tutorials/minitutorial/1.1.x.txt · Last modified: 2012/04/15 08:36 by laurent

Recent changes RSS feed Creative Commons License