Differences

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

english:other-enhancements:hacks:guestbook-hide_entry [2010/02/10 21:15]
Claus
english:other-enhancements:hacks:guestbook-hide_entry [2018/06/03 18:09] (current)
Line 8: Line 8:
**Explanation:** **Explanation:**
-  * After submitting a new entry, a "[##]" is placed at the beginning of the message text automatically ////(mini-hack)//.+  * After submitting a new entry, a "[##]" is placed at the beginning of the message text automatically //(mini-hack)//.
  * All entries including a "[##]" will not be displayed in the FE output, or an alternative text is displayed. //(Template/cp-trigger Script)//.   * All entries including a "[##]" will not be displayed in the FE output, or an alternative text is displayed. //(Template/cp-trigger Script)//.
  * If "%%[##]%%" will be deleted from the entry in BE, the entry in FE will become visible.  //("[##]" can also be added in BE in order to hide entries)//.   * If "%%[##]%%" will be deleted from the entry in BE, the entry in FE will become visible.  //("[##]" can also be added in BE in order to hide entries)//.
\\ \\
 +
**Blocked Messages:** **Blocked Messages:**
-{{:deutsch:andere-erweiterungen:hacks:gb_entry_hide_fe01_1.gif| }}+ 
 +{{:english:other-enhancements:hacks:gb_entry_hide_fe01_en_1.gif| }}
{{:deutsch:andere-erweiterungen:hacks:gb_entry_hide_be01_2.gif|}} {{:deutsch:andere-erweiterungen:hacks:gb_entry_hide_be01_2.gif|}}
 +
 +\\
**Unlocked Entries:** **Unlocked Entries:**
 +
{{:deutsch:andere-erweiterungen:hacks:gb_entry_hide_fe02_1.gif| }} {{:deutsch:andere-erweiterungen:hacks:gb_entry_hide_fe02_1.gif| }}
{{:deutsch:andere-erweiterungen:hacks:gb_entry_hide_be02_2.gif|}} {{:deutsch:andere-erweiterungen:hacks:gb_entry_hide_be02_2.gif|}}
 +
 +
\\ \\
Line 29: Line 36:
- as there are: - as there are:
 +
  - enter the switch **$phpwcms['guestbook_hidden']  = 1;** in conf.inc.php   - enter the switch **$phpwcms['guestbook_hidden']  = 1;** in conf.inc.php
  - The file **include/inc_front/content/cnt18.article.inc.php** has to be changed a little bit //(small hack)//   - The file **include/inc_front/content/cnt18.article.inc.php** has to be changed a little bit //(small hack)//
Line 35: Line 43:
\\ \\
 +
---- ----
 +
Docu: -- \\ Docu: -- \\
Forum: -- Forum: --
Line 47: Line 57:
---- ----
 +
\\ \\
**Tag** //(in template)//: **Tag** //(in template)//:
Line 58: Line 69:
In In
<code html><!--##:Alternative AlternativText:##//--></code> <code html><!--##:Alternative AlternativText:##//--></code>
-the text is entered which will be shown in case the entry is locked.+the text is entered which will be shown in case the entry is locked, e.g. ''%%<!--##:<h2>{TIMESTAMP:d.m.Y H:i}</h2> :##//-->%%''.
**%%<!--##%%:**AlternativeText AlternativeText**:%%##//-->%%** has to be set anywhere between **%%<!--##Begin-{DBID}##//-->%%** and **%%<!--##End-{DBID}##//-->%%** . \\ **%%<!--##%%:**AlternativeText AlternativeText**:%%##//-->%%** has to be set anywhere between **%%<!--##Begin-{DBID}##//-->%%** and **%%<!--##End-{DBID}##//-->%%** . \\
Line 73: Line 84:
  <!--##Begin-{DBID}##//-->   <!--##Begin-{DBID}##//-->
-    <!--##:<h1 style="padding-top:10px">Entry on {TIMESTAMP:m/d/Y H:i} by {NAME}</h1>:##//-->+   <!--##:<h1 style="padding-top:10px">Entry on {TIMESTAMP:m/d/Y H:i} by {NAME}</h1>:##//-->
    <h1><span class="entryID">entry #{ID} by </span>[URL]<a href="{URL}" target="_blank">{NAME}</a>[/URL][URL_ELSE]{NAME}[/URL_ELSE]</h1>     <h1><span class="entryID">entry #{ID} by </span>[URL]<a href="{URL}" target="_blank">{NAME}</a>[/URL][URL_ELSE]{NAME}[/URL_ELSE]</h1>
Line 100: Line 111:
\\ \\
-==== Codeschnipsel (Hack) ====+==== Code snippet (hack) ====
**File name:** cnt18.article.inc.php \\ **File name:** cnt18.article.inc.php \\
Line 178: Line 189:
<note important> <note important>
-Der Tag %%<!--##:SUBSTITUTETEXT SUBSTITUTETEXT SUBSTITUTETEXT:##//-->%% has to be between \\+The Tag %%<!--##:SUBSTITUTETEXT SUBSTITUTETEXT SUBSTITUTETEXT:##//-->%% has to be between \\
**%%<!--##Begin-{DBID}##//-->%%** \\ **%%<!--##Begin-{DBID}##//-->%%** \\
%%<!--##:SUBSTITUTETEXT SUBSTITUTETEXT SUBSTITUTETEXT:##//-->%% \\ %%<!--##:SUBSTITUTETEXT SUBSTITUTETEXT SUBSTITUTETEXT:##//-->%% \\
**%%<!--##End-{DBID}##//-->%%** \\ **%%<!--##End-{DBID}##//-->%%** \\
-stehen. 
</note> </note>
Line 189: Line 199:
==== PHP ==== ==== PHP ====
-**Dateiname:** cp_trig_guestbook.php \\ +In the area **%%CUSTOM VAR ==========================%%** \\ 
-**Ort:**   template/inc_script/frontend_init/ +an additional text can be entered in **$replacement_text**, which is issued when an item is not yet released. This text will be displayed only if in template also the tag ''%%<!--##:AlternativText AlternativText:##//-->%%'' is used. 
 + 
 +---- 
 +\\ 
 + 
 +**File name:** cp_trig_guestbook.php \\ 
 +**Location:**   template/inc_script/frontend_init/
<code php |h cp_trig_guestbook.php |h > <code php |h cp_trig_guestbook.php |h >
Line 241: Line 257:
// additional replacement text // additional replacement text
- $replacement_text = ' <span style="color:red"> &nbsp;[[Der Eintrag wird bearbeitet]]</span><br><br>'.LF;+// $replacement_text = ' <span style="color:red"> &nbsp;[[Der Eintrag wird bearbeitet]]</span><br><br>'.LF; 
 + $replacement_text = ' <span style="color:red"> &nbsp;[[The entry will be processed]]</span><br><br>'.LF;
// ===================================== // =====================================
english/other-enhancements/hacks/guestbook-hide_entry.1265832941.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