Differences

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

english:phpwcms_replacer_rts:frontend_render:tag-site-structure [2009/11/28 16:55]
Knut Heermann (flip-flop)
english:phpwcms_replacer_rts:frontend_render:tag-site-structure [2018/06/03 18:09] (current)
Line 13: Line 13:
\\ \\
-**Procedure:** +===== Procedure: ===== 
In the site structure in the field ** "category infotext" ** by ** "HOME" ** // (ie ID = 0) // is entered a tag which controls the behavior of the RT in /frontend_render/ , e.g. In the site structure in the field ** "category infotext" ** by ** "HOME" ** // (ie ID = 0) // is entered a tag which controls the behavior of the RT in /frontend_render/ , e.g.
-<file>[JAHRESZEITEN] #Tag1, #Tag2, Tag3,.#Tag4,...[/JAHRESZEITEN]</file>+<file>[JAHRESZEITEN] #Tag1, #Tag2, Tag3, #Tag4,...[/JAHRESZEITEN]</file>
The wrapper **[JAHRESZEITEN]** separates the tags from the remaining entries in this field. \\ The wrapper **[JAHRESZEITEN]** separates the tags from the remaining entries in this field. \\
Not valid tags are simply disabled by using a leading **#**. //(In the above example the tag **Tag3** is active). // Not valid tags are simply disabled by using a leading **#**. //(In the above example the tag **Tag3** is active). //
Line 39: Line 40:
-**CSS:** \\+===== Replace css file: ===== 
A new CSS file is loaded, depending on the day. In order not to change the load sequence of the CSS files, a dummy or a fallback CSS file is created in template/inc_css/* and in the correct place in the template involved. A new CSS file is loaded, depending on the day. In order not to change the load sequence of the CSS files, a dummy or a fallback CSS file is created in template/inc_css/* and in the correct place in the template involved.
Line 71: Line 73:
{{:deutsch:ersetzer_rts:frontend_render:be_template03-3_1.gif|}} {{:deutsch:ersetzer_rts:frontend_render:be_template03-3_1.gif|}}
-----+
\\ \\
-===== Content ersetzen: =====+===== Replace content: =====
-Natürlich ist es auch möglich bestimmten Content auszutauschen. +Of course, it is also possible to share certain content.
-Im  unteren Bereich  des Skriptes  **V1.1** sind einige Beispiel aufgezeigt //(Custom Funktionen)//. +In the lower section of the script **V1.1** are shown some examples //(Custom Functions)//.
-**Bsp01.:** direktes ersetzen im Template/Content  +**Bsp01.:** direct replacement in the template/content //direktes ersetzen im Template/Content//  
-  * Die php Function ##str_replace('Suchmuster', 'wird ersetzt durch', 'zu durchsuchender Inhalt');## wird verwendet. \\ $content['all'] = str_replace('Suchmich Wort',Tolles Wort', $content['all']); +  * The php function ##str_replace('Suchmuster', 'wird ersetzt durch', 'zu durchsuchender Inhalt');## is used. \\ $content['all'] = str_replace('Suchmich Wort',Tolles Wort', $content['all']);
\\ \\
-**Bsp02.:** Ersetzen mit Umschlieszer (wrapper) im Template/Content +**Bsp02.:** Replace with wrapper in template/Content  
 + 
 +In template/content we see e.g.: "Jetzt **[SEASON]**im Jahr ist es farbig**[/SEASON]**." 
 + 
 +  * With the help of the built-in-funtion ##replace_cnt_template('crawler content', 'TAG', 'is replaced by');## it can quite easily be implemented. \\ $content['all'] = replace_cnt_template($content['all'], SEASON, 'im Winter ist es weiß');
-In der Vorlage/Content steht z.B.: "Jetzt **[SEASON]**im Jahr ist es farbig**[/SEASON]**." 
-  * Mit Hilfe der eingebauten Funtion ##replace_cnt_template('zu durchsuchender Inhalt', 'TAG', 'wird ersetzt durch');## kann das recht einfach realisiert werden: \\ $content['all'] = replace_cnt_template($content['all'], SEASON, 'im Winter ist es weiß'); 
\\ \\
-**Bsp03.:** Ersetzen mit Tag **{TAG}** im Template/Content+**Bsp03.:** Replacing with tag **{TAG}** in template/content
-In der Vorlage/Content steht z.B.: "Jetzt ist der **{SEASON}** da."+In template/content we see e.g.: "Jetzt ist der **{SEASON}** da."
-  *  Wie oben wird hier die php Funktion ##str_replace(...); ## verwendet. \\ $content['all'] = str_replace('{SEASON}', 'Winter', $content['all']);+  *  As noted above, here the php function ##str_replace(...); ## used. \\ $content['all'] = str_replace('{SEASON}', 'Winter', $content['all']);
\\ \\
-Sicherheitshalber muss nun noch geprüft werden, ob noch Umschließer-Reste im Content vorhanden sind //(Das passiert z.B. wenn kein TAG trifft)//. +The safe side now needs to be examined whether there are wrapped-snippets are present in the content //(This happens for example if no TAG is true )//.
-Dazu kommt noch die Voreinstellung //(Fallback)// bei einem Einzelersetzer wie z.B. **{ERSETZE}**. Trifft kein Tag aus unserer Liste, muss hier ein Default-Wert eingetragen werden. \\+In addition we must have a look to the pre-setting //(fallback)// like e.g., **{ERSETZE}**. If no tag from our list matches, a default value must be registered here. \\
-  * $content['all'] = str_replace('{ERSETZE}', 'Default-Wert', $content['all']);  +  * $content['all'] = str_replace('{ERSETZE}', 'default value', $content['all']);  
english/phpwcms_replacer_rts/frontend_render/tag-site-structure.1259423711.txt.gz · Last modified: 2018/06/03 18:08 (external edit)
www.planmatrix.de www.chimeric.de Creative Commons License Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0