Message_XH

Ein CMSimple Support Forum für deutsch sprechende Nutzer und Entwickler
mhz
Posts: 676
Joined: Tue Jun 25, 2013 8:46 pm
Location: Heusenstamm, Hessen
Contact:

Message_XH

Post by mhz » Fri Oct 17, 2014 8:21 pm

Hallo zusammen,
ich habe mir das Plugin message_xh von der Seite http://www.cmsimplewiki.com heruntergeladen und installiert.
Nach dem Hochladen wurde bei mir automatisch im "language-Ordner" die Datei "de.php! erzeugt.
Es kam es zum white-screen mit der Meldung
A fatal error occurred. Enable debug mode for further information.
Im dann aktivierten debug-Modus war die Meldung detaillierter:
Parse error: syntax error, unexpected 'http' (T_STRING) in URL/plugins/message/languages/de.php on line 3.
Lösung: Wenn ihr bei das Plugin Message_XH findet und einsetzen möchtet, solltet ihr vor dem Heraufladen ins Plugins-Verzeichnis in einem Editor die Datei "en.php" im language-Ordner bearbeiten. Dort ist in Zeile 3 dieser Link vorgegeben
Der ist aber anscheinend nicht (mehr) gültig und erzeugt diesen Fehler. Löscht ihr den vorher (mit den noch folgenden Größenangaben), speichert die Datei dann auch als "de.php" ab und ladet ihr diese erst dann hoch, funktioniert alles.

Gruß
Michael
Michael Zajusch (mhz)-- Mein Tutorial für CMSimple_XH. Früher

cmb
Posts: 14225
Joined: Tue Jun 21, 2011 11:04 am
Location: Bingen, RLP, DE
Contact:

Re: Message_XH

Post by cmb » Fri Oct 17, 2014 8:49 pm

Hallo Michael,

danke für das Melden des Problems und das präsentieren einer brauchbaren Lösung. :)
mhz wrote:Der ist aber anscheinend nicht (mehr) gültig und erzeugt diesen Fehler.
Der Bild-URL ist tatsächlich nicht mehr gültig, aber das ist nicht das eigentliche Problem, sondern die Syntax in der Sprachdatei (auch die Original-Sprachdatei müsste einen White Screen verursachen). Es müsste richtig lauten:

Code: Select all

$plugin_tx['message']['message']="<p>Add txt here or banner <img src=\"http://3-magi.net/plugins/privacy/privacy.png\" width=\"128\" height=\"128\"></p>"; 
(Innerhalb eines PHP-Strings in doppelten Anführungszeichen muss enthaltenen doppelten Anführungszeichen ein Backslash vorangestellt werden.)
mhz wrote:Nach dem Hochladen wurde bei mir automatisch im "language-Ordner" die Datei "de.php! erzeugt.
Das ist übrigens normal, wenn eine erforderliche Sprachdatei fehlt. Diese wird dann beim ersten Aufruf der Site einfach als Kopie von default.php oder en.php erzeugt.

Christoph
Christoph M. Becker – Plugins for CMSimple_XH

mhz
Posts: 676
Joined: Tue Jun 25, 2013 8:46 pm
Location: Heusenstamm, Hessen
Contact:

Re: Message_XH

Post by mhz » Fri Oct 17, 2014 9:09 pm

Danke für den neuen Code, Christoph!
Nun funktioniert es.
Mit der "Original-Sprachdatei en.php" hätte es vermutlich auch das Problem gegeben, aber die habe ich gleich mitgeändert gehabt.

Gruß
Michael
Michael Zajusch (mhz)-- Mein Tutorial für CMSimple_XH. Früher

cmb
Posts: 14225
Joined: Tue Jun 21, 2011 11:04 am
Location: Bingen, RLP, DE
Contact:

Re: Message_XH

Post by cmb » Fri Oct 17, 2014 9:17 pm

mhz wrote:Mit der "Original-Sprachdatei en.php" hätte es vermutlich auch das Problem gegeben, aber die habe ich gleich mitgeändert gehabt.
Ja, ich denke schon. Ich habe das Problem im Message_XH Artikel auf cmsimplewiki.com nun auch dokumentiert. Wenn Du dort noch keinen Account hast, aber einen möchtest, dann gib einfach Bescheid (die Registriermöglichkeit musste aufgrund von heftigen Spam-Attacken leider abgeschaltet werden).
Christoph M. Becker – Plugins for CMSimple_XH

oldnema
Posts: 265
Joined: Wed Jan 21, 2009 5:15 pm
Location: Czech Republic
Contact:

Re: Message_XH

Post by oldnema » Sat Oct 18, 2014 11:13 am

Hello Christoph. I completely overlooked this useful plugin and I really like it. I miss it but one important setting. Would it be possible to add a plugin backend option that "Message_xh" can hide?
It seems impractical, even though no text plugin is visible. Delete or comment out the call to the plugin template is somewhat laborious.
Thank you for your time.
Josef
Nobody knows how much time he has left ...
http://oldnema.compsys.cz/en/?Demo_templates

cmb
Posts: 14225
Joined: Tue Jun 21, 2011 11:04 am
Location: Bingen, RLP, DE
Contact:

Re: Message_XH

Post by cmb » Sat Oct 18, 2014 5:38 pm

Hi Josef,

well, Message_XH is not my plugin, but it is rather a fork of one of my plugins (Privacy_XH) made by twc.

Anyway, what about the following solution for your request? Instead of adding a config option (or modifying the plugin in some other way), just insert into the template:

Code: Select all

<?php if ($plugin_tx['message']['message'] != '') message()?>
This way the message will only be displayed, if the "message" field in the language settings is not empty.

Christoph
Christoph M. Becker – Plugins for CMSimple_XH

oldnema
Posts: 265
Joined: Wed Jan 21, 2009 5:15 pm
Location: Czech Republic
Contact:

Re: Message_XH

Post by oldnema » Sat Oct 18, 2014 6:16 pm

Hi Chris, I inserted code into the template, but nothing is displayed. CMS_XH Version 1.6.4.
Will it work?
Josef
Nobody knows how much time he has left ...
http://oldnema.compsys.cz/en/?Demo_templates

twc
Posts: 233
Joined: Fri Jun 18, 2010 12:25 am
Location: Netherlands

Re: Message_XH

Post by twc » Sat Oct 18, 2014 6:40 pm

i got this CMSimple_XH 1.6.4 2014092901

A fatal error occurred. Enable debug mode for further information.

mhz
Posts: 676
Joined: Tue Jun 25, 2013 8:46 pm
Location: Heusenstamm, Hessen
Contact:

Re: Message_XH

Post by mhz » Sat Oct 18, 2014 7:13 pm

twc,
and which informations show the debug mode?
Michael Zajusch (mhz)-- Mein Tutorial für CMSimple_XH. Früher

oldnema
Posts: 265
Joined: Wed Jan 21, 2009 5:15 pm
Location: Czech Republic
Contact:

Re: Message_XH

Post by oldnema » Sat Oct 18, 2014 7:45 pm

twc wrote:i got this CMSimple_XH 1.6.4 2014092901

A fatal error occurred. Enable debug mode for further information.
cmb wrote:

Code: Select all

$plugin_tx['message']['message']="<p>Add txt here or banner <img src=\"http://3-magi.net/plugins/privacy/privacy.png\" width=\"128\" height=\"128\"></p>"; 
(Innerhalb eines PHP-Strings in doppelten Anführungszeichen muss enthaltenen doppelten Anführungszeichen ein Backslash vorangestellt werden.)
Josef
Nobody knows how much time he has left ...
http://oldnema.compsys.cz/en/?Demo_templates

Post Reply