Skip to content
Snippets Groups Projects
Commit 90f557c6 authored by Torsten Oppermann's avatar Torsten Oppermann
Browse files

[TASK] Documentation wip

parent 3de7760e
No related branches found
No related tags found
No related merge requests found
......@@ -12,20 +12,23 @@ TYPO3 version: >7.6
## About
Integrates a powerful News-System. News and Categories can be created as normal TYPO3 pages. Newspages have several
Integrates a powerful News-System. News and Categories can be created like normal TYPO3 pages. Newspages have several
additional meta information.
## Integration
sg_news will not be an install & forget extension as we needs some rendering information for the frontend. This
means you need to provide some information how the extension needs to integrated into your template. As the
extension itself provides two new doktypes, we can simply add a switch case to our typoscript fluid template
to provide different rendering paths. Please look at the example below:
Before using sg_news you need to supply your frontend some information on how the extension needs to be integrated into your template.
As the extension itself provides two new [doktypes](https://docs.typo3.org/typo3cms/CoreApiReference/PageTypes/Index.html), you can simply add a switch case to your Fluid template to provide different rendering paths.
### Example
```
lib.pageTemplate.default >
lib.pageTemplate.default = FLUIDTEMPLATE
lib.pageTemplate.default {
# your default page template
file = EXT:project_theme/Resources/Private/Templates/Default.html
variables {
......@@ -68,20 +71,20 @@ lib.pageTemplate.default {
}
```
In this example we will load by default the first column for the intro section and the second column in the backend
for the content below that. The news category (doktype 117) will render by default not the content on the page alone,
but also the default category listing. The related extension plugin knows itself how to render on such a page. The
news page itself also get's some special rendering information here. In our case we don't want the intro section
rendered and also not the default content as the extension itself handles the special content rendering for it's
special case by referencing the singleview extension plugin of sg_news.
In this example we will load the first column for the intro section by default
and the second column in the backend for the content below that.
The news category (doktype 117) will render by default not the content on the page alone, but also the default category listing.
The single news plugin also needs some additional knowledge from there it can get the base content. Please provide
in your typoscript the information of lib.mainContent. By default it will resolve to the following code if not
provided by you:
With our example we don't want the intro section (116) and the default content to be rendered, because the extension handles those parts.
The single news plugin also needs some additional information so it can get the base content.
By default it will resolve to the following code if not provided by you:
```
lib.mainContent < styles.content.col1
```
### Tags
In addition to categories, multiple tags can be created and specified for each news page.
......@@ -90,3 +93,7 @@ In order to differentiate each block's tags from the others, the PageTS value of
can be set for each of the blocks containing the pid value for the selectable tags.
To make sure that only the correct tags are displayed in the FE, the **plugin.tx_sgnews.settings.tagPid**
constant must be set to the same value.
## Creating a news category
## Creating news entries
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment