summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Templates.md155
1 files changed, 77 insertions, 78 deletions
diff --git a/Templates.md b/Templates.md
index 7ddc728..d081abc 100644
--- a/Templates.md
+++ b/Templates.md
@@ -1,4 +1,3 @@
-# Documentation: Templates
**WARNING:** Parameters marked with **{!}** must be escaped from HTML markup if you display them!
├── html
@@ -33,7 +32,7 @@
└── rsrc
└── […]
-## Template `html/*`
+## Global `html/*`
The following variables are available in **each** other template file:
* `$BLOGMETA['NAME']`**{!}**: Global available: The name of the blog
@@ -42,62 +41,71 @@ The following variables are available in **each** other template file:
* `$BLOGMETA['MAIL']`: Global available: The email address of the contact person
* `$BLOGMETA['LANG']`: Global available: The two-letter language code for the content
-## Template `html/feed/index.php`
-Basic framework of the RSS feed in XML which contains a list of page and post items:
+## Main Template `html/main.php`
+Basic framework of the HTML document which contains the main content:
-* `$FEED['TYPE']`: Contains a string if a feed for a specific item group is requested (either `post` or `page`)
-* `$FEED['LIST']['POSTS']`: Contains a list of post items (or is empty when the "pages-only" feed is requested)
-* `$FEED['LIST']['PAGES']`: Contains a list of page items (or is empty when the "posts-only" feed is requested)
+* `$HEAD['NAME']`**{!}**: Contains the document name for the `<title>` tag or something else
+* `$HEAD['DESC']`**{!}**: Contains the document description for `<meta` tags or something else
+* `$HEAD['PERM']`: Contains the canonical URL for this document
+* `$HEAD['OG_IMAGES']`: Contains a list of image URLs for the document
+* `$HTML`: Contains the documents main body (other templates)
-## Template `html/feed/item_page.php`
-Represents a single page to display within the feed template.
+## Home Template `html/home.php`
+This is the default startpage template which contains a list with the last posts.
-* `$PAGE`: [See reference for `@PAGE`]
-* `$USER`: [See reference for `@USER`]
+* `$LIST['POSTS']`: Contains a list of post items for the home site
+* `$PAGEINATION['HTML']`: Contains the pageination template with the list navigation
-## Template `html/feed/item_post.php`
-Represents a single post to display within the feed template.
+## Page List Template `html/page/list.php`
+Overview template which contains the site navigation and a list of page items to be displayed.
-* `$POST`: [See reference for `@POST`]
-* `$USER`: [See reference for `@USER`]
+* `$LIST['PAGES']`: Contains a list of page items for the current site
+* `$PAGINATION['THIS']`: Contains the current site number of the list navigation
+* `$PAGINATION['LAST']`: Contains the last site number of the list navigation
+* `$PAGINATION['HTML']`: Contains the pageination template with the list navigation
-## Template `html/page/item.php`
-Represents a single page to display within the list template.
+## Post List Template `html/post/list.php`
+Overview template which contains the site navigation and a list of post items to be displayed.
-* `$PAGE`: [See reference for `@PAGE`]
-* `$USER`: [See reference for `@USER`]
+* `$LIST['POSTS']`: Contains a list of post items for the current site
+* `$PAGINATION['THIS']`: Contains the current site number of the list navigation
+* `$PAGINATION['LAST']`: Contains the last site number of the list navigation
+* `$PAGINATION['HTML']`: Contains the pageination template with the list navigation
-## Template `html/page/list.php`
-Overview template which contains the site navigation and a list of page items to be displayed.
+## User List Template `html/user/list.php`
+Overview template which contains the site navigation and a list of user items to be displayed.
-* `$LIST['PAGES']`: Contains a list of page items for the current site
-* `$PAGEINATION['THIS']`: Contains the current site number of the list navigation
-* `$PAGEINATION['LAST']`: Contains the last site number of the list navigation
-* `$PAGEINATION['HTML']`: Contains the pageination template with the list navigation
+* `$LIST['USERS']`: Contains a list of user items for the current site
+* `$PAGINATION['THIS']`: Contains the current site number of the list navigation
+* `$PAGINATION['LAST']`: Contains the last site number of the list navigation
+* `$PAGINATION['HTML']`: Contains the pageination template with the list navigation
-## Template `html/page/main.php`
-Main template for a single page.
+## Page Item Template `html/page/item.php`
+Represents a single page to display within the list template.
* `$PAGE`: [See reference for `@PAGE`]
* `$USER`: [See reference for `@USER`]
-* `$PAGE['PREV']`: Same data structure as `$PAGE` but with the data from the previous page
-* `$PAGE['NEXT']`: Same data structure as `$PAGE` but with the data from the next page
-## Template `html/post/item.php`
+## Post Item Template `html/post/item.php`
Represents a single post to display within the list template.
* `$POST`: [See reference for `@POST`]
* `$USER`: [See reference for `@USER`]
-## Template `html/post/list.php`
-Overview template which contains the site navigation and a list of post items to be displayed.
+## User Item Template `html/user/item.php`
+Represents a single user to display within the list template.
-* `$LIST['POSTS']`: Contains a list of post items for the current site
-* `$PAGEINATION['THIS']`: Contains the current site number of the list navigation
-* `$PAGEINATION['LAST']`: Contains the last site number of the list navigation
-* `$PAGEINATION['HTML']`: Contains the pageination template with the list navigation
+* `$USER`: [See reference for `@USER`]
+
+## Page Main Template `html/page/main.php`
+Main template for a single page.
+
+* `$PAGE`: [See reference for `@PAGE`]
+* `$USER`: [See reference for `@USER`]
+* `$PAGE['PREV']`: Same data structure as `$PAGE` but with the data from the previous page
+* `$PAGE['NEXT']`: Same data structure as `$PAGE` but with the data from the next page
-## Template `html/post/main.php`
+## Post Main Template `html/post/main.php`
Main template for a single post.
* `$POST`: [See reference for `@POST`]
@@ -105,7 +113,16 @@ Main template for a single post.
* `$POST['PREV']`: Same data structure as `$POST` but with the data from the previous post
* `$POST['NEXT']`: Same data structure as `$POST` but with the data from the next post
-## Template `html/search/index.php`
+## User Main Template `html/user/main.php`
+Main template for a single user.
+
+* `$USER`: [See reference for `@USER`]
+* `$USER['PREV']`: Same data structure as `$USER` but with the data from the previous user
+* `$USER['NEXT']`: Same data structure as `$USER` but with the data from the next user
+* `$COUNT['POST']`: Contains the number of posts published by the user
+* `$COUNT['PAGE']`: Contains the number of pages published by the user
+
+## Search Request Template `html/search/main.php`
Search template without results and with the formular.
* `$SEARCH['TEXT']`**{!}**: Contains the full search string
@@ -117,7 +134,7 @@ Search template without results and with the formular.
* `$FORM['OPTIONS']['M']`: Contains a list of possible months to select
* `$FORM['OPTIONS']['Y']`: Contains a list of possible years to select
-## Template `html/search/result.php`
+## Search Result Template `html/search/result.php`
Result template with a list of posts and the formular to repeat the search.
* `$SEARCH['TEXT']`**{!}**: Contains the full search string
@@ -130,60 +147,42 @@ Result template with a list of posts and the formular to repeat the search.
* `$FORM['OPTIONS']['M']`: Contains a list of possible months to select
* `$FORM['OPTIONS']['Y']`: Contains a list of possible years to select
-## Template `html/user/item.php`
-Represents a single user to display within the list template.
+## Pagination Template `html/pagination.php`
+Contains the site navigation for post, page and user list (and for the home template)
-* `$USER`: [See reference for `@USER`]
+* `$THIS`: Contains the current site number of the list navigation
+* `$LAST`: Contains the last site number of the list navigation
+* `$HREF`: Contains the URL for a specific site number
-## Template `html/user/list.php`
-Overview template which contains the site navigation and a list of user items to be displayed.
+## Feed Template `html/feed/main.php`
+Basic framework of the RSS feed in XML which contains a list of page and post items:
-* `$LIST['USERS']`: Contains a list of user items for the current site
-* `$PAGEINATION['THIS']`: Contains the current site number of the list navigation
-* `$PAGEINATION['LAST']`: Contains the last site number of the list navigation
-* `$PAGEINATION['HTML']`: Contains the pageination template with the list navigation
+* `$FEED['TYPE']`: Contains a string if a feed for a specific item group is requested (either `post` or `page`)
+* `$FEED['LIST']['POSTS']`: Contains a list of post items (or is empty when the "pages-only" feed is requested)
+* `$FEED['LIST']['PAGES']`: Contains a list of page items (or is empty when the "posts-only" feed is requested)
-## Template `html/user/main.php`
-Main template for a single user.
+## Feed Item Template [page] `html/feed/item_page.php`
+Represents a single page to display within the feed template.
+* `$PAGE`: [See reference for `@PAGE`]
* `$USER`: [See reference for `@USER`]
-* `$USER['PREV']`: Same data structure as `$USER` but with the data from the previous user
-* `$USER['NEXT']`: Same data structure as `$USER` but with the data from the next user
-* `$COUNT['POST']`: Contains the number of posts published by the user
-* `$COUNT['PAGE']`: Contains the number of pages published by the user
-## Template `html/403.php`
+## Feed Item Template [post] `html/feed/item_post.php`
+Represents a single post to display within the feed template.
+
+* `$POST`: [See reference for `@POST`]
+* `$USER`: [See reference for `@USER`]
+
+## 403 Template `html/403.php`
Default template for error page 403 Forbidden.
*[no variables]*
-## Template `html/404.php`
+## 404 Template `html/404.php`
Default template for error page 404 Not Found.
*[no variables]*
-## Template `html/home.php`
-This is the default startpage template which contains a list with the last posts.
-
-* `$LIST['POSTS']`: Contains a list of post items for the home site
-* `$PAGEINATION['HTML']`: Contains the pageination template with the list navigation
-
-## Template `html/main.php`
-Basic framework of the HTML document which contains the main content:
-
-* `$HEAD['NAME']`**{!}**: Contains the document name for the `<title>` tag or something else
-* `$HEAD['DESC']`**{!}**: Contains the document description for `<meta` tags or something else
-* `$HEAD['PERM']`: Contains the canonical URL for this document
-* `$HEAD['OG_IMAGES']`: Contains a list of image URLs for the document
-* `$HTML`: Contains the documents main body (other templates)
-
-## Template `html/pageination.php`
-Contains the site navigation for post, page and user list (and for the home template)
-
-* `$THIS`: Contains the current site number of the list navigation
-* `$LAST`: Contains the last site number of the list navigation
-* `$HREF`: Contains the URL for a specific site number
-
## References to reduce duplicate text
### `@PAGE`