From efa8b9e7ce1c700d31fee7d16351159ac5f2e71f Mon Sep 17 00:00:00 2001 From: carl <> Date: Wed, 18 Jan 2006 15:01:50 +0000 Subject: Fixed a name bug Template pages --- .../protected/pages/Configurations/Templates1.page | 6 +++--- .../protected/pages/Configurations/Templates2.page | 12 ++++++------ .../protected/pages/Configurations/Templates3.page | 10 +++++----- 3 files changed, 14 insertions(+), 14 deletions(-) (limited to 'demos/quickstart/protected/pages') diff --git a/demos/quickstart/protected/pages/Configurations/Templates1.page b/demos/quickstart/protected/pages/Configurations/Templates1.page index ce539281..37a389ba 100644 --- a/demos/quickstart/protected/pages/Configurations/Templates1.page +++ b/demos/quickstart/protected/pages/Configurations/Templates1.page @@ -6,7 +6,7 @@ Templates are used to specify the presentational layout of controls. A template
The template format is like HTML, with a few PRADO-specifc tags, including component tags, template control tags, comment tags, dynamic content tags, and dynamic property tags. .
- +A component tag specifies a component as part of the body content of the template control. If the component is a control, it usually will become a child or grand child of the template control, and its rendering result will be inserted at the place where it is appearing in the template. @@ -36,7 +36,7 @@ PropertyValue It is equivalent to ...PropertyName="PropertyValue"... in every aspect. Property initialization tags must be directly enclosed between the corresponding opening and closing component tag.
- +
Comment tags are used to put comments in the template or the ultimate rendering result. There are two types of comment tags. One is like that in HTML and will be displayed to the end-users. The other only appear in a template and will be stripped out when the template is instantiated and displayed to the end-users. The format of these two comment tags is as follows,
diff --git a/demos/quickstart/protected/pages/Configurations/Templates2.page b/demos/quickstart/protected/pages/Configurations/Templates2.page
index cace46b3..ca8d7de4 100644
--- a/demos/quickstart/protected/pages/Configurations/Templates2.page
+++ b/demos/quickstart/protected/pages/Configurations/Templates2.page
@@ -1,13 +1,13 @@
Dynamic content tags are introduced as shortcuts to some commonly used component tags. These tags are mainly used to render contents resulted from evaluating some PHP expressions or statements. They include expression tags, statement tags, databind tags, parameter tags, asset tags and localization tags.
An expression tag represents a PHP expression that is evaluated when the template control is being rendered. The expression evaluation result is inserted at the place where the tag resides in the template. Its format is as follows,
@@ -20,7 +20,7 @@ Inernally, an expression tag is represented by a TExpression control. T
Templates: Part II
-
+
Dynamic Content Tags
Expression Tags
Statement tags are similar to expression tags, except that statement tags contain PHP statements rather than expressions. The output of the PHP statements (using for example echo or print in PHP) are displayed at the place where the statement tag resides in the template. Inernally, a statement tag is represented by a TStatements control. Therefore, in the statements $this refers to the TStatements control. The format of statement tags is as follows, @@ -40,7 +40,7 @@ echo strftime("%A %e %B %Y",time());
- +Databind tags are similar to expression tags, except that the expressions are evaluated only when a dataBind() call is invoked on the controls representing the databind tags. Internally, a TLiteral control is used to represent a databind tag and $this in the expression would refer to the control. The format of databind tags is as follows, @@ -49,7 +49,7 @@ Databind tags are similar to expression tags, except that the expressions are ev
- +Parameter tags are used to insert application parameters at the place where they appear in the template. The format of parameter tags is as follows, @@ -59,7 +59,7 @@ Parameter tags are used to insert application parameters at the place where they Note, application parameters are usually defined in application configurations or page directory configurations. The parameters are evaluated when the template is instantiated.
- +
Asset tags are used to publish private files and display the corresponding the URLs. For example, if you have an image file that is not Web-accessible and you want to make it visible to end-users, you can use asset tags to publish this file and show the URL to end-users so that they can fetch the published image.
diff --git a/demos/quickstart/protected/pages/Configurations/Templates3.page b/demos/quickstart/protected/pages/Configurations/Templates3.page
index bec25d13..c1e58e25 100644
--- a/demos/quickstart/protected/pages/Configurations/Templates3.page
+++ b/demos/quickstart/protected/pages/Configurations/Templates3.page
@@ -1,7 +1,7 @@
Dynamic property tags are very similar to dynamic content tags, except that they are applied to component properties. The purpose of dynamic property tags is to allow more versatile component property configuration. Note, you are not required to use dynamic property tags because what can be done using dynamic property tags can also be done in PHP code. However, using dynamic property tags bring you much more convenience at accomplishing the same tasks. The basic usage of dynamic property tags is as follows,
@@ -16,7 +16,7 @@ where you may enclose DynamicPropertyTag within single or double quotes
Like dynamic content tags, we have expression tags, databind tags, parameter tags, asset tags and localization tags. (Note, there is no statement tag here.)
An expression tag represents a PHP expression that is evaluated when the template is being instantiated. The expression evaluation result is assigned to the corresponding component property. The format of expression tags is as follows,
@@ -32,7 +32,7 @@ In the expression, $this refers to the component specified by the compo
Note, unlike dynamic content tags, the expressions tags for component properties are evaluated when the components are being constructed, while for the dynamic content tags, the expressions are evaluated when the controls are being rendered.
Databind tags are similar to expression tags, except that they can only be used with control properties and the expressions are evaluated only when a dataBind() call is invoked on the controls represented by the component tags. In the expression, $this refers to the control itself. Databind tags do not apply to all components. They can only be used for controls.
@@ -44,7 +44,7 @@ The format of databind tags is as follows,
Parameter tags are used to assign application parameter values to the corresponding component properties. The format of parameter tags is as follows,
@@ -54,7 +54,7 @@ Parameter tags are used to assign application parameter values to the correspond
Note, application parameters are usually defined in application configurations or page directory configurations. The parameters are evaluated when the template is instantiated.
Asset tags are used to publish private files and assign the corresponding the URLs to the component properties. For example, if you have an image file that is not Web-accessible and you want to make it visible to end-users, you can use asset tags to publish this file and show the URL to end-users so that they can fetch the published image.
--
cgit v1.2.3
Templates: Part III
-
+
Dynamic Property Tags
Expression Tags
Databind Tags
Parameter Tags
Asset Tags