Third Party Plugins to CMSimple - how to install, use and create plugins
Moderator: Tata
-
Tata
- Posts: 3587
- Joined: Tue May 20, 2008 5:34 am
- Location: Slovakia
-
Contact:
Post
by Tata » Wed May 29, 2019 5:55 am
Ich habe eine Seite mit vielen PDFs in vielen Ordner verteilt und den Plugin dazu instelliert, um diese "OrdnerInhalte" in verlinkten Listen zu zeigen.
Z.B.:
Die Seitenstrukture
Seitenstruktur.png
Die Ordnerstrukture
Userfiles.png
Weiter nutze ich noch Accordion Plugin. So habe ich auf:
Code: Select all
<h2>Povinne zverejňované</h2>
{{{accpand}}}
<h3>Evidencia oprávnených nákladov v DSS</h3>
{{{wdir('downloads/dokumenty/povinné/EON-ZPB','*.pdf');}}}
Problem:
Am Localhost funktioniert alles super. Am Host funktioniert der Accordion gut, und auch die Spaltenúberschriffte kommen auf, aber die Dateien werden nicht gelistet.
Result.png
Verschiedenes ohne Erfolg versucht. Egal, ob mit Wdir_XH 1.0beta2, oder Wdir 1.7. Und ich würde die Lösung ziemlich bald finden brauchen. Hat jemand eine Idee?
Testbeispiel:
https://cmsimple.sk/socialtrans/?Dokume ... erejnovane
You do not have the required permissions to view the files attached to this post.
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.
-
SiNiTaSa
- Posts: 114
- Joined: Tue Jan 03, 2017 10:33 am
- Location: BW|GERMANY
Post
by SiNiTaSa » Wed May 29, 2019 8:25 am
Probier es mal so ?
Code: Select all
<div>{{{wdir("downloads/dokumenty/povinné/EON-ZPB");}}}</div>
-
Tata
- Posts: 3587
- Joined: Tue May 20, 2008 5:34 am
- Location: Slovakia
-
Contact:
Post
by Tata » Wed May 29, 2019 10:06 am
Das habe ich schon auch versucht. Am Lokalhost geht beides. Am Host nicht mehr. Es ist zwar mit CMSimple_XH 1.6.10. Jetzt habe ich unter 1.7.2. probiert. Lokal - kein Problem. Es wird jetzt hochgeladen. Mal sehen...
Und noch eine Frage: geht es z.B. die Spalte mit Datum ausblenden?
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.
-
SiNiTaSa
- Posts: 114
- Joined: Tue Jan 03, 2017 10:33 am
- Location: BW|GERMANY
Post
by SiNiTaSa » Wed May 29, 2019 10:50 am
Sie die Unterverzeichnisse im Plugin config/, css/, languages/ und den Datenordner des Plugins beschreibbar.
-
Tata
- Posts: 3587
- Joined: Tue May 20, 2008 5:34 am
- Location: Slovakia
-
Contact:
Post
by Tata » Wed May 29, 2019 11:00 am
Klar, alle Ordner sind vom Server gleich auf 755 und die Dateien dann auf 644 eingestellt.
Welcher ist aber der Datenordner? Hier
search.php?keywords=error%3A+counter habe ich gefunden, dass es muss manuell der orden /content/plugins/wdir erstellt werden. Sonst hatte ich auch die Meldung.
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.
-
SiNiTaSa
- Posts: 114
- Joined: Tue Jan 03, 2017 10:33 am
- Location: BW|GERMANY
Post
by SiNiTaSa » Wed May 29, 2019 11:35 am
ist der Ordner erstellt worden ?
unter
/content/plugins/wdir
wenn nicht dann erstelle unter /content
den Ordner plugins und darin den Ordner wdir
-
cmb
- Posts: 14225
- Joined: Tue Jun 21, 2011 11:04 am
- Location: Bingen, RLP, DE
-
Contact:
Post
by cmb » Thu May 30, 2019 9:40 am
Tata wrote: ↑Wed May 29, 2019 5:55 am
Am Localhost funktioniert alles super. Am Host funktioniert der Accordion gut, und auch die Spaltenúberschriffte kommen auf, aber die Dateien werden nicht gelistet.
Das sind Zeichensatz/-kodierungsprobleme. CMSimple_XH arbeitet intern mit UTF-8. Anscheinend auch dein localhost (unter Windows wird ab PHP 7.1 intern nach Bedarf umgewandelt), aber wohl nicht der Sever. Schnelle Lösung: nur ASCII-Zeichen in den Dateinamen verwenden.
-
Tata
- Posts: 3587
- Joined: Tue May 20, 2008 5:34 am
- Location: Slovakia
-
Contact:
Post
by Tata » Thu May 30, 2019 10:04 am
Ja, genau das war das Problem. Nachdem die Ordner richtig umgenannt wurden (nur mit ASCII Zeichen), geht alles richtig.
Weill ich auf der Seite nur die PDFs anbiete, ist es nicht unbedingt nötig die Dateien runterzuladen, um sie zu lesen. Besser nur im neuen Fenster zu öffnen. Da habe ich in der TableView.php kleine Veränderung gemacht.
Code: Select all
}else{
$fo .= $this->renderFileIcon($file);
$fo .= '<input type="button" value="'.$file->getName().'" onclick="wdir_download(\''.$pathcode.'\',\''.$index.'zae'.$key.'\')" style="cursor: pointer;"/></td>';
}
//. '<a href="' . $file->getPath() . '" target="_blank">'.$file->getName().'</a>'.'</td>'
zu
Code: Select all
}else{
$fo .= $this->renderFileIcon($file);
// $fo .= '<input type="button" value="'.$file->getName().'" onclick="wdir_download(\''.$pathcode.'\',\''.$index.'zae'.$key.'\')" style="cursor: pointer;"/></td>';
$fo .= '<a href="' . $file->getPath() . '" target="_blank">'.$file->getName().'</a>'.'</td>';
}
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.