First commit

This commit is contained in:
2025-02-28 08:45:43 +01:00
commit 1f4e772600
1122 changed files with 74621 additions and 0 deletions

View File

@ -0,0 +1,60 @@
<?php
/*
============================================================
CMSimple Plugin CoAuthors
============================================================
Version: CoAuthors 3.0
Released: 10/2023
Copyright: Gert Ebersbach
Internet: www.ge-webdesign.de/cmsimple/
============================================================
utf-8 check: äöü
*/
initvar('co_authors');
if ($co_authors)
{
if(!defined('CMSIMPLE_VERSION'))
{
$o.= '<p>This plugin requires <b>CMSimple 4.2</b> or higher.</p><p><a href="http://www.cmsimple.org/">CMSimple Download & Updates &raquo;</a></p>';
return;
}
// Make CMSimple variables accessible
global $sn,$sv,$sl,$pth,$plugin;
// Detect the foldername of the plugin.
$plugin=basename(dirname(__FILE__),"/");
$admin = isset($_GET['admin']) ? $_GET['admin'] : '';
$admin .= isset($_POST['admin']) ? $_POST['admin'] : '';
// Parameter "ON" shows the Plugin Main Tab.
// Blank "" or "OFF" does not show the Plugin Main Tab.
$o.=print_plugin_admin('off');
// First page when loading the plugin.
if ($admin == '' || $admin == 'plugin_main')
{
$o.='
<h4>Plugin CoAuthors</h4>
<hr>
<ul>
<li>Version: CoAuthors 3.0</li>
<li>Released: 2023-10</li>
<li>Copyright: Gert Ebersbach</li>
<li>Internet: <a href="http://www.ge-webdesign.de/cmsimpleplugins/?Eigene_Plugins">www.ge-webdesign.de</a></li>
</ul>
<hr>
<p><b>No admin options</b></p>
';
}
if ($admin <> 'plugin_main')
{
$hint=array();
$hint['mode_donotshowvarnames'] = false;
$o.=plugin_admin_common($action, $admin, $plugin, $hint);
}
}
?>

View File

@ -0,0 +1,106 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<title>CoAuthors Kurzdoku</title>
<meta name="content-language" content="de">
<style type="text/css">
body {font-family: arial, sans-serif; line-height: 1.4em;}
div#main {Width: 900px; padding: 24px; margin: 0 auto;}
h1, h2 {color: #720; margin-top: 90px;}
h3, h4 {margin-top: 60px;}
p.code {font-family: Courier New; border: 1px solid #999; background: #eed; padding: 8px 12px;}
span.code {font-family: Courier New; color: #620;}
td {border: 1px solid; padding: 8px 12px;}
li {padding-top: 5px; padding-bottom: 5px;}
a:link, a:visited {color: #249;}
a:hover {color: #c60;}
</style>
</head>
<body>
<!-- utf-8 check: äöüß -->
<div id="main">
<p style="font-size: 24px;"><a href="http://translate.google.de/" target="_blank">Google translator &raquo;</a></p>
<p>(Opens in a new window - öffnet in einem neuen Fenster)</p><hr>
<h1>Kurz-Dokumentation Plugin "CoAuthors"</h1>
<p><b><i>Version CoAuthors 3.0</i></b> - released 10/2023</p>
<p><b>CoAuthors</b> ist ein CMSimple Plugin, mit dem txt-Dateien, die html Quelltext enthalten und die irgendwo in einem Unterverzeichnis einer CMSimple Installation liegen, in eine Seite dieser CMSimple Installation eingebunden werden können.</p>
<p style="background: #fc0; color: #000; text-align: center; font-weight: 700; border: 2px solid #000; padding: 10px 16px;">Der Plugin Aufruf für CMSimpleCoAuthors entfernt alle h1 Überschriften aus dem Quelltext.</p>
<div style="background: #f3f6f9; border: 3px solid #c60; text-align: center; padding: 0 24px;">
<p>Mit einer <a href="http://www.ge-webdesign.de/co_authors/"><b>CoAuthors Subsite &raquo;</b></a> können Sie solche txt-Dateien einfach und komfortabel in Ihrer gewohnten Arbeitsumgebung erzeugen.</p>
</div>
<h2>1. Systemvoraussetzungen</h2>
<p>Voraussetzung ist eine funktionierende Installation von CMSimple 4.0 oder höher.</p>
<hr>
<h2>2. Installation</h2>
<ol>
<li>zip-Datei herunterladen und mit einem geeigneten Programm entpacken</li>
<li>Laden Sie den Ordner "co_authors" in das Verzeichnis "plugins" Ihrer CMSimple Installation hoch.</li>
</ol>
<hr>
<h2>3. Datei- und Ordnerrechte</h2>
<p>Die Vergabe von Schreibrechten für Ordner und Dateien ist nicht notwendig.</p>
<hr>
<h2>4. Plugin-Aufruf</h2>
<p style="background: #fc0; color: #000; text-align: center; font-weight: 700; border: 2px solid #000; padding: 10px 16px;">Der Plugin Aufruf für CMSimpleCoAuthors entfernt alle h1 Überschriften aus dem Quelltext.</p>
<h3>4.1 Plugin-Aufruf für CMSimpleCoAuthors</h3>
<p>Fügen Sie folgenden Plugin-Aufruf in Ihre CMSimple Seite ein, an der Stelle, an der die txt-Datei eingebunden werden soll:</p>
<p class="code">{{{plugin:co_authors('CoAuthorFolder/','Die_Autoren_Seite');}}}</p>
<p><span style="color: rgb(128, 0, 0); font-weight: 700;">Hinweis: Bitte fügen Sie den Plugin Aufruf immer in der Quelltext Ansicht ein.</span></p>
<p><b>CoAuthorFolder:</b> Das Verzeichnis, in dem CMSimpleCoAuthors - also die Autoren Installation - installiert ist.</p>
<p><span style="color: rgb(128, 0, 0); font-weight: 700;">!!! WICHTIG !!!</span> der Slash ("/") am Ende, ohne den funktioniert's nicht.</p>
<p><b>Die_Autoren_Seite:</b> Der Name der Seite der Autoren Installation, die eingebunden werden soll, mit "_" für die Leerstellen.</p>
<p><span style="color: rgb(128, 0, 0); font-weight: 700;">!!! WICHTIG !!!</span> Bitte bei den Namen der Autorenseiten keine Umlaute oder Sonderzeichen verwenden, da daraus Dateinamen gemacht werden, die an CMSimple übergeben werden.</p>
<h3>4.2 Plugin-Aufruf mit vollem URL</h3>
<p>Fügen Sie folgenden Plugin-Aufruf in Ihre CMSimple Seite ein, an der Stelle, an der die txt-Datei eingebunden werden soll:</p>
<p class="code">{{{plugin:co_authorsURL('Datei mit vollem URL');}}}</p>
<p><span style="color: rgb(128, 0, 0); font-weight: 700;">Hinweis: Bitte fügen Sie den Plugin Aufruf immer in der Quelltext Ansicht ein.</span></p>
<p><b>Beispiel - Example:</b></p>
<p class="code">{{{plugin:co_authorsURL('./userfiles/texte/text01.txt');}}}</p>
<h2>5. Konfiguration</h2>
<p>Für <b>CoAuthors</b> gibt es keine Konfigurations Optionen.</p>
</div>
</body>
</html>

View File

@ -0,0 +1,61 @@
<?php
/*
============================================================
CMSimple Plugin CoAuthors
============================================================
Version: CoAuthors 3.0
Released: 10/2023
Copyright: Gert Ebersbach
Internet: www.ge-webdesign.de/cmsimple/
============================================================
utf-8 check: äöü
*/
function co_authors($co_author_folder, $co_author_page)
{
global $pth;
if(!defined('CMSIMPLE_VERSION'))
{
return '<p>This plugin requires <b>CMSimple 4.2</b> or higher.</p><p><a href="http://www.cmsimple.org/">CMSimple Download & Updates &raquo;</a></p>';
}
$GLOBALS['co_author_folder'] = $co_author_folder; global $co_author_folder;
// echo 'von co_author: ' . $co_author_folder . $co_author_page . '<br>'; // for development only
$co_author_doc = '';
// $co_author_doc.= '<p class="cmsimplecore_warning" style="clear: both; font-family: arial, sans-serif; font-size: 12px; text-align: center;">Die folgenden Inhalte wurden extern mit CMSimpleCoAutors erstellt und mit dem Plugin CoAuthors in diese Website eingebunden:</p>';
$co_author_doc.= file_get_contents($pth['folder']['base'].$co_author_folder.'userfiles/co_author/' . $co_author_page . '.txt');
$co_author_doc = preg_replace('~<h1(.*)</h1>~', '', $co_author_doc);
$co_author_doc = evaluate_scripting($co_author_doc);
return($co_author_doc);
}
function co_authorsURL($fileURL)
{
global $pth;
if(!defined('CMSIMPLE_VERSION'))
{
return '<p>This plugin requires <b>CMSimple 4.2</b> or higher.</p><p><a href="http://www.cmsimple.org/">CMSimple Download & Updates &raquo;</a></p>';
}
$co_author_doc = '';
// $co_author_doc.= '<p class="cmsimplecore_warning" style="clear: both; font-family: arial, sans-serif; font-size: 12px; text-align: center;">Die folgenden Inhalte wurden extern mit CMSimpleCoAutors erstellt und mit dem Plugin CoAuthors in diese Website eingebunden:</p>';
$co_author_doc.= file_get_contents($fileURL);
$co_author_doc = evaluate_scripting($co_author_doc);
return($co_author_doc);
}
?>

View File

@ -0,0 +1 @@
CoAuthors,2023100701,3.0,,,http://www.ge-webdesign.de/cmsimpleplugins/?Eigene_Plugins___CoAuthors,http://www.ge-webdesign.de/downloads/versioninfo/coauthors/version.nfo

View File

@ -0,0 +1,40 @@
.cch1s_container {
clear: both;
max-width: 600px;
background: #e0e6e9;
color: #333;
border: 3px solid #900;
border-radius: 5px;
padding: 6px 16px;
margin: 0 0 24px 0;
margin: 0 auto;
}
.cch1s_todo {
color: #900;
font-weight: 700;
}
.cch1s_done {
background: #080;
color: #fff;
font-weight: 700;
text-align: center;
padding: 12px;
}
.cch1s_container hr {
height: 2px;
clear: both;
color: #567;
background-color: #567;
border: 0;
margin: 16px 0;
}
.cch1s_container a:link {color: #258; text-decoration: none;}
.cch1s_container a:visited {color: #258; text-decoration: none;}
.cch1s_container a:hover {color: #c60; text-decoration: underline;}
.cch1s_container a:active {color: #c60; text-decoration: underline;}
.cch1s_container a:focus {color: #c60; text-decoration: underline;}

View File

@ -0,0 +1,160 @@
<?php
if (!defined('CMSIMPLE_VERSION') || preg_match('#/convert_h1split/index.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
if(!defined('PLUGINLOADER')) {
die('Plugin '. basename(dirname(__FILE__)) . ' requires a newer version of the Pluginloader. No direct access.');
}
// convert content to h1only splitting
if ($adm && isset($_GET['convert_content_to_h1only']) && !strstr(file_get_contents('./content/content.php'),'class="_level1_page_"'))
{
copy($pth['file']['content'], $pth['folder']['content'] . 'SIK_content_4-to-5_' . date("Ymd_His") . '.php');
copy($pth['file']['pagedata'], $pth['folder']['content'] . 'SIK_pagedata_4-to-5_' . date("Ymd_His") . '.php');
$contemp = file_get_contents('./content/content.php');
// create CMSimple 5 headings
if($cf['menu']['levels'] == '6')
{
// clean h1-6 tags
$contemp = preg_replace('/<h1.*?>/i','<h1>',$contemp);
$contemp = preg_replace('/<h2.*?>/i','<h2>',$contemp);
$contemp = preg_replace('/<h3.*?>/i','<h3>',$contemp);
$contemp = preg_replace('/<h4.*?>/i','<h4>',$contemp);
$contemp = preg_replace('/<h5.*?>/i','<h5>',$contemp);
$contemp = preg_replace('/<h6.*?>/i','<h6>',$contemp);
$contemp = str_ireplace('<h1>','<h1 class="_level1_page_">',$contemp);
$contemp = str_ireplace('<h2>','<h1 class="_level2_page_">',$contemp);
$contemp = str_ireplace('</h2>','</h1>',$contemp);
$contemp = str_ireplace('<h3>','<h1 class="_level3_page_">',$contemp);
$contemp = str_ireplace('</h3>','</h1>',$contemp);
$contemp = str_ireplace('<h4>','<h1 class="_level4_page_">',$contemp);
$contemp = str_ireplace('</h4>','</h1>',$contemp);
$contemp = str_ireplace('<h5>','<h1 class="_level5_page_">',$contemp);
$contemp = str_ireplace('</h5>','</h1>',$contemp);
$contemp = str_ireplace('<h6>','<h1 class="_level6_page_">',$contemp);
$contemp = str_ireplace('</h6>','</h1>',$contemp);
}
if($cf['menu']['levels'] == '5')
{
// clean h1-5 tags
$contemp = preg_replace('/<h1.*?>/i','<h1>',$contemp);
$contemp = preg_replace('/<h2.*?>/i','<h2>',$contemp);
$contemp = preg_replace('/<h3.*?>/i','<h3>',$contemp);
$contemp = preg_replace('/<h4.*?>/i','<h4>',$contemp);
$contemp = preg_replace('/<h5.*?>/i','<h5>',$contemp);
$contemp = str_ireplace('<h1>','<h1 class="_level1_page_">',$contemp);
$contemp = str_ireplace('<h2>','<h1 class="_level2_page_">',$contemp);
$contemp = str_ireplace('</h2>','</h1>',$contemp);
$contemp = str_ireplace('<h3>','<h1 class="_level3_page_">',$contemp);
$contemp = str_ireplace('</h3>','</h1>',$contemp);
$contemp = str_ireplace('<h4>','<h1 class="_level4_page_">',$contemp);
$contemp = str_ireplace('</h4>','</h1>',$contemp);
$contemp = str_ireplace('<h5>','<h1 class="_level5_page_">',$contemp);
$contemp = str_ireplace('</h5>','</h1>',$contemp);
}
if($cf['menu']['levels'] == '4')
{
// clean h1-4 tags
$contemp = preg_replace('/<h1.*?>/i','<h1>',$contemp);
$contemp = preg_replace('/<h2.*?>/i','<h2>',$contemp);
$contemp = preg_replace('/<h3.*?>/i','<h3>',$contemp);
$contemp = preg_replace('/<h4.*?>/i','<h4>',$contemp);
$contemp = str_ireplace('<h1>','<h1 class="_level1_page_">',$contemp);
$contemp = str_ireplace('<h2>','<h1 class="_level2_page_">',$contemp);
$contemp = str_ireplace('</h2>','</h1>',$contemp);
$contemp = str_ireplace('<h3>','<h1 class="_level3_page_">',$contemp);
$contemp = str_ireplace('</h3>','</h1>',$contemp);
$contemp = str_ireplace('<h4>','<h1 class="_level4_page_">',$contemp);
$contemp = str_ireplace('</h4>','</h1>',$contemp);
}
if($cf['menu']['levels'] == '3')
{
// clean h1-3 tags
$contemp = preg_replace('/<h1.*?>/i','<h1>',$contemp);
$contemp = preg_replace('/<h2.*?>/i','<h2>',$contemp);
$contemp = preg_replace('/<h3.*?>/i','<h3>',$contemp);
$contemp = str_ireplace('<h1>','<h1 class="_level1_page_">',$contemp);
$contemp = str_ireplace('<h2>','<h1 class="_level2_page_">',$contemp);
$contemp = str_ireplace('</h2>','</h1>',$contemp);
$contemp = str_ireplace('<h3>','<h1 class="_level3_page_">',$contemp);
$contemp = str_ireplace('</h3>','</h1>',$contemp);
}
if($cf['menu']['levels'] == '2')
{
// clean h1-2 tags
$contemp = preg_replace('/<h1.*?>/i','<h1>',$contemp);
$contemp = preg_replace('/<h2.*?>/i','<h2>',$contemp);
$contemp = str_ireplace('<h1>','<h1 class="_level1_page_">',$contemp);
$contemp = str_ireplace('<h2>','<h1 class="_level2_page_">',$contemp);
$contemp = str_ireplace('</h2>','</h1>',$contemp);
}
if($cf['menu']['levels'] == '1')
{
// clean h1 tags
$contemp = preg_replace('/<h1.*?>/i','<h1>',$contemp);
$contemp = str_ireplace('<h1>','<h1 class="_level1_page_">',$contemp);
}
$content4 = $contemp;
// write content.php
$h1only_convertContentHandle = './content/content.php';
$content4handle = fopen($h1only_convertContentHandle, "w+");
fwrite($content4handle,$content4);
fclose($content4handle);
header('Location: ./?converted_content_to_h1only');
}
// plugin output
if($adm && $cf['use']['h1only_pagesplitting'] == 'true' && !strstr(file_get_contents('./content/content.php'),'class="_level1_page_"'))
{
$o.= '<div class="cch1s_container">';
$o.= '
<h1>' . $plugin_tx['convert_content']['headline_plugin'] . '</h1>
<p>' . $plugin_tx['convert_content']['text_config_changed'] . '</p>
<div style="background: #fff; border: 2px solid; padding: 0 12px;">
<p>' . $plugin_tx['convert_content']['text_config_changed_back1'] . '</p>
<p>' . $plugin_tx['convert_content']['text_config_changed_back2'] . '</p>
<!-- <p style="text-align: right;"><a href="./?file=config&action=array"><b>Zur CMS Konfiguration &raquo;</b></a></p> -->
</div>
';
$o.= '<p>' . $plugin_tx['convert_content']['text_plugin_description'] . '</p>
<p class="cmsimplecore_warning" style="text-align: center; padding: 12px;"><b>' . $plugin_tx['convert_content']['text_usage_hint'] . '<br>
' . $plugin_tx['convert_content']['text_backup_hint'] . '</b></p>
';
$o.= '<p style="text-align: right;"><br><a href="./?convert_content_to_h1only"><b>' . $plugin_tx['convert_content']['text_convert_content'] . ' h1only_pagesplitting &raquo;</b></a></p>';
$o.= '</div>';
}
if(isset($_GET['converted_content_to_h1only']))
{
$o.= '<p class="cch1s_done">' . $plugin_tx['convert_content']['text_conversion_complete'] . '</p>';
}
?>

View File

@ -0,0 +1,16 @@
<?php // utf-8 Marker: äöü
$plugin_tx['convert_content']['headline_plugin']="Plugin convert_h1split";
$plugin_tx['convert_content']['text_backup_hint']="Machen Sie ein Backup der gesamten Installation, bevor Sie irgendetwas tun!";
$plugin_tx['convert_content']['text_config_changed']="Sie haben die CMS Konfiguration auf h1only_pagesplitting umgestellt.";
$plugin_tx['convert_content']['text_config_changed_back1']="Sie können zur alten Splitting Methode zurückkehren, indem Sie in der CMS Konfiguration das folgende Feld leer lassen:";
$plugin_tx['convert_content']['text_config_changed_back2']="Einstellungen => CMS => Use => H1only_pagesplitting:";
$plugin_tx['convert_content']['text_config_changed_back3']="Zur CMS Konfiguration &raquo;";
$plugin_tx['convert_content']['text_conversion_complete']="Die Konvertierung zu h1only_pagesplitting ist komplett.";
$plugin_tx['convert_content']['text_convert_content']="Konvertiere die Inhaltsdatei (content.php) zu ";
$plugin_tx['convert_content']['text_h1only_pagesplitting']="h1only_pagesplitting";
$plugin_tx['convert_content']['text_plugin_description']="Jetzt müssen Sie noch Ihre Inhaltsdatei (content.php) auf die neue Seitensplitting-Methode h1only_pagesplitting umstellen. Dabei werden alle evtl. vorhandenen Styles, Klassen und IDs der Hauptüberschriften der CMSimple Seiten entfernt.";
$plugin_tx['convert_content']['text_usage_hint']="Verwenden Sie diese Funktionen nicht auf öffentlichen Internetseiten!";
$plugin_tx['convert_content']['utf8_marker']="äöü";
?>

View File

@ -0,0 +1,16 @@
<?php // utf-8 Marker: äöü
$plugin_tx['convert_content']['headline_plugin']="Plugin convert_h1split";
$plugin_tx['convert_content']['text_backup_hint']="Make a backup of the whole installation, before you do anything!";
$plugin_tx['convert_content']['text_config_changed']="You have changed the CMS configuration to h1only_pagesplitting.";
$plugin_tx['convert_content']['text_config_changed_back1']="You can go back to the old splitting method by leaving the following field blank in the CMS configuration:";
$plugin_tx['convert_content']['text_config_changed_back2']="Settings => CMS => Use => H1only_pagesplitting:";
$plugin_tx['convert_content']['text_config_changed_back3']="To the CMS configuration &raquo;";
$plugin_tx['convert_content']['text_conversion_complete']="Converting to h1only_pagesplitting is complete.";
$plugin_tx['convert_content']['text_convert_content']="Convert content file (content.php) to ";
$plugin_tx['convert_content']['text_h1only_pagesplitting']="h1only_pagesplitting";
$plugin_tx['convert_content']['text_plugin_description']="Now you have to convert your content file (content.php) to the new page-splitting method h1only_pagesplitting. All eventual existing styles, classes and IDs of the main headings of the CMSimple pages will be removed.";
$plugin_tx['convert_content']['text_usage_hint']="Do not use this functions on public websites!";
$plugin_tx['convert_content']['utf8_marker']="äöü";
?>

View File

@ -0,0 +1,16 @@
<?php // utf-8 Marker: äöü
$plugin_tx['convert_content']['headline_plugin']="Plugin convert_h1split";
$plugin_tx['convert_content']['text_backup_hint']="Make a backup of the whole installation, before you do anything!";
$plugin_tx['convert_content']['text_config_changed']="You have changed the CMS configuration to h1only_pagesplitting.";
$plugin_tx['convert_content']['text_config_changed_back1']="You can go back to the old splitting method by leaving the following field blank in the CMS configuration:";
$plugin_tx['convert_content']['text_config_changed_back2']="Settings => CMS => Use => H1only_pagesplitting:";
$plugin_tx['convert_content']['text_config_changed_back3']="To the CMS configuration &raquo;";
$plugin_tx['convert_content']['text_conversion_complete']="Converting to h1only_pagesplitting is complete.";
$plugin_tx['convert_content']['text_convert_content']="Convert content file (content.php) to ";
$plugin_tx['convert_content']['text_h1only_pagesplitting']="h1only_pagesplitting";
$plugin_tx['convert_content']['text_plugin_description']="Now you have to convert your content file (content.php) to the new page-splitting method h1only_pagesplitting. All eventual existing styles, classes and IDs of the main headings of the CMSimple pages will be removed.";
$plugin_tx['convert_content']['text_usage_hint']="Do not use this functions on public websites!";
$plugin_tx['convert_content']['utf8_marker']="äöü";
?>

View File

@ -0,0 +1,101 @@
<?php
if (!defined('CMSIMPLE_VERSION') || preg_match('#/filebrowser/admin.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
/* utf-8 marker: äöü */
if (!$adm || $cf['filebrowser']['external']) {
return true;
}
initvar('filebrowser');
function filebrowserSafeQS($querystring)
{
return(htmlspecialchars(strip_tags($querystring), ENT_QUOTES, 'UTF-8'));
}
if ($filebrowser) {
$plugin = basename(dirname(__FILE__));
$plugin = basename(dirname(__FILE__), "/");
$o .= '<div class="plugintext">
<div class="plugineditcaption">
Filebrowser for CMSimple
</div>
<hr />
<p>' . $tx['message']['plugin_standard1'] . '</p><p>' . $tx['message']['plugin_standard2'] . ' <a href="./?file=config&amp;action=array"><b>' . $tx['filetype']['config'] . '</b></a></p>
<hr />
<p>Author: <a href="http://zeichenkombinat.de/" target="_blank">Martin Damken</a></p>
<p>Adapted for CMSimple 4.0 and higher by <a href="http://www.ge-webdesign.de/" target="_blank">ge-webdesign.de</a></p>
</div>';
return;
}
if(!($images || $downloads || $userfiles || $media)) {
return true;
}
if(isset($_GET['subdir']) && strstr($_GET['subdir'],'userfiles/images/')) {
$f = 'images';
}
if(isset($_GET['subdir']) && strstr($_GET['subdir'],'userfiles/downloads/')) {
$f = 'downloads';
}
if(isset($_GET['subdir']) && strstr($_GET['subdir'],'userfiles/media/')) {
$f = 'media';
}
if($userfiles && $f != 'images' && $f != 'downloads' && $f != 'media'){$f = 'userfiles';}
$browser = $_SESSION['fb_browser'];
define('CMSIMPLE_FB_PATH', $pth['folder']['plugins'] . 'filebrowser/');
$hjs .= '<script type="text/javascript" src="' . CMSIMPLE_FB_PATH . 'js/filebrowser.js"></script>';
$subdir = isset($_GET['subdir']) ? str_replace(array('..', '.'), '', $_GET['subdir']) : '';
if (strpos($subdir, $browser->baseDirectories['userfiles']) !== 0) {
$subdir = $browser->baseDirectories[$f];
}
$browser->baseDirectory = $browser->baseDirectories['userfiles'];
$browser->currentDirectory = filebrowserSafeQS(rtrim($subdir, '/')) . '/';
$browser->linkType = $f;
$browser->setLinkParams('userfiles');
if (isset($_POST['deleteFile']) && isset($_POST['file'])) {
csrfProtection();
$browser->deleteFile($_POST['file']);
}
if (isset($_POST['deleteFolder']) && isset($_POST['folder'])) {
csrfProtection();
$browser->deleteFolder($_POST['folder']);
}
if (isset($_POST['upload'])) {
csrfProtection();
$browser->uploadFile();
}
if (isset($_POST['createFolder'])) {
csrfProtection();
$browser->createFolder();
}
if (isset($_POST['renameFile'])) {
csrfProtection();
$browser->renameFile();
}
$browser->readDirectory();
$o .= $browser->render('cmsbrowser');
$f = 'filebrowser';
$images = $downloads = $userfiles = $media = false;
/*
* EOF filebrowser/admin.php
*/
?>

View File

@ -0,0 +1,392 @@
<?php
if (preg_match('#/filebrowser/classes/filebrowser.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
/* utf-8 marker: äöü */
class CMSimpleFileBrowser {
var $linkPrefix = '';
var $browseBase = '';
var $baseDirectory;
var $currentDirectory;
var $linkType;
var $folders = array();
var $files = array();
var $baseDirectories = array();
var $allowedExtensions = array();
var $maxFilesizes = array();
var $view;
var $message = '';
var $browserPath = '';
function __construct() {
global $pth, $plugin_cf, $cf, $userfiles_path, $userfiles_path_images, $userfiles_path_downloads, $userfiles_path_media;
/*
$image_extensions = array();
$temp = explode(',', $cf['filebrowser']['extensions_images']);
foreach ($temp as $ext) {
$extension = trim($ext, ' ./');
if ((bool) $extension) {
$image_extensions[] = strtolower($extension);
}
}
$download_extensions = array();
$temp = explode(',', $cf['filebrowser']['extensions_downloads']);
foreach ($temp as $ext) {
$extension = trim($ext, ' ./');
if ((bool) $extension) {
$download_extensions[] = strtolower($extension);
}
}
$media_extensions = array();
$temp = explode(',', $cf['filebrowser']['extensions_media']);
foreach ($temp as $ext) {
$extension = trim($ext, ' ./');
if ((bool) $extension) {
$media_extensions[] = strtolower($extension);
}
}
*/
$userfiles_extensions = array();
$temp = explode(',', $cf['filebrowser']['extensions_userfiles']);
foreach ($temp as $ext) {
$extension = trim($ext, ' ./');
if ((bool) $extension) {
$userfiles_extensions[] = strtolower($extension);
}
}
$this->browserPath = $pth['folder']['plugins'] . basename(dirname(dirname(__FILE__))) . '/';
$this->view = new CMSimpleFileBrowserView();
$this->baseDirectories['images'] = $userfiles_path_images;
$this->baseDirectories['downloads'] = $userfiles_path_downloads;;
$this->baseDirectories['userfiles'] = $userfiles_path;
$this->baseDirectories['media'] = $userfiles_path_media;
$this->allowedExtensions['images'] = $userfiles_extensions;
$this->allowedExtensions['downloads'] = $userfiles_extensions;
$this->allowedExtensions['userfiles'] = $userfiles_extensions;
$this->allowedExtensions['media'] = $userfiles_extensions;
}
function fileIsLinked($file) {
global $h, $c, $u;
$i = 0;
$usages = array();
foreach ($c as $page) {
if (preg_match('#<.*(src|href|download)=["|\'].*' . $file . '["|\'].*>#i', $page) > 0) {
$usages[] = '<a href="?' . $u[$i] . '">' . $h[$i] . '</a>';
}
$i++;
}
$usages = array_unique($usages);
if (count($usages) > 0) {
return $usages;
}
return false;
}
function readDirectory() {
$dir = $this->browseBase . $this->currentDirectory;
$this->files = array();
$handle = opendir($dir);
if ($handle) {
while (false !== ($file = readdir($handle))) {
if (strpos($file, '.') === 0) {
continue;
}
if (is_dir($dir . $file)) {
$this->folders[] = $this->currentDirectory . $file;
continue;
}
if ($this->isAllowedFile($file)) {
$this->files[] = $file;
}
}
closedir($handle);
natcasesort($this->folders);
natcasesort($this->files);
}
}
function getFolders($directory) {
$folders = array();
$handle = opendir($directory);
if ($handle) {
while (false !== ($file = readdir($handle))) {
if (strpos($file, '.') === 0) {
continue;
}
if (is_dir($directory . $file)) {
$folders[] = str_replace($this->browseBase, '', $directory . $file);
foreach ($this->getFolders($directory . $file . '/') as $subfolder) {
$folders[] = $subfolder;
}
}
}
closedir($handle);
natcasesort($folders);
}
return $folders;
}
function isAllowedFile($file) {
$extension = strtolower(pathinfo($file, PATHINFO_EXTENSION));
if ($extension == $file) {
return false;
}
if (!in_array($extension, $this->allowedExtensions[$this->linkType])
&& !in_array('*', $this->allowedExtensions[$this->linkType])) {
return false;
}
return true;
}
function foldersArray($all = true) {
$folders = array();
$temp = $this->getFolders($this->browseBase . $this->baseDirectory);
$baseDepth = count(explode('/', $this->baseDirectory)) - 2;
foreach ($temp as $i => $folder) {
$ar = explode('/', $folder);
$level = count($ar);
$parent = '';
for ($i = 0; $i < $level - 1; $i++) {
$parent .= '/' . $ar[$i];
}
$parent = substr($parent, 1);
$folders[$folder]['level'] = count($ar) - $baseDepth;
$folders[$folder]['parent'] = $parent;
$folders[$folder]['children'] = array();
$linkList = '';
}
foreach ($folders as $folder => $data) {
$folders[$folder]['children'] = $this->gatherChildren($folder, $folders);
}
$this->view->currentDirectory = $this->currentDirectory;
foreach ($folders as $folder => $data) {
$folders[$folder]['linkList'] = $this->view->folderLink($folder, $folders);
}
return $folders;
}
function gatherChildren($parent, $folders) {
$children = array();
foreach ($folders as $key => $folder) {
if ($folder['parent'] == $parent) {
$children[] = $key;
}
}
return $children;
}
function deleteFile($file) {
$file = $this->browseBase . $this->currentDirectory . basename($file);
if (is_array($this->fileIsLinked($file)))
{
$this->view->message .= '<div class="cmsimplecore_warning"><p>';
$this->view->error('error_not_deleted', $file);
$this->view->message .= '</p><p>';
$this->view->error('error_file_is_used', $file);
$this->view->message .= '</p>';
foreach ($this->fileIsLinked($file) as $page)
{
$this->view->message .= '<ul style="font-weight: 300;"><li>' . $page . '</li>';
}
$this->view->message .= '</ul></div>';
return;
}
if (unlink($file)) {
$this->view->success('success_deleted', $file);
} else {
$this->view->error('error_not_deleted', $file);
}
}
function uploadFile()
{
$file = $_FILES['fbupload'];
$dir = explode('/',$this->currentDirectory);
if (isset($this->maxFilesizes[$dir[1]]))
{
if ($file['size'] > $this->maxFilesizes[$dir[1]]) {
$this->view->message.= '<p class="cmsimplecore_warning" style="text-align: center;">';
$this->view->error('error_not_uploaded', $file['name']);
$this->view->error('error_file_too_big', array(number_format($file['size']/1000, 2), number_format($this->maxFilesizes[$dir[1]]/1000, 2)));
$this->view->message.= '</p>';
return;
}
}
if ($file['error'] != 0)
{
$this->view->error('error_not_uploaded', $file['name']);
return;
}
$filename = $this->browseBase . $this->currentDirectory . basename($file['name']);
if (file_exists($filename))
{
$this->view->message.= '<p class="cmsimplecore_warning" style="text-align: center;">';
$this->view->error('error_not_uploaded', $file['name']);
$this->view->error('error_file_already_exists', $filename);
$this->view->message.= '</p>';
return;
}
if ($this->isAllowedFile($file['name']) == false)
{
$this->view->message.= '<p class="cmsimplecore_warning" style="text-align: center;">';
$this->view->error('error_not_uploaded', $file['name']);
$this->view->error('error_no_proper_extension', pathinfo($file['name'], PATHINFO_EXTENSION));
$this->view->message.= '</p>';
return;
}
if (move_uploaded_file($_FILES['fbupload']['tmp_name'], $filename))
{
chmod($filename, 0666);
$this->view->success('success_uploaded', $file['name']);
return;
}
$this->view->error('error_not_uploaded', $file['name']);
}
function createFolder()
{
$folder = basename($_POST['createFolder']);
$folder = str_replace(array(':', '*', '?', '"', '<', '>', '|', '.'), '', $folder);
$folder = str_replace(array(' ', ' ', ' ', ' ', ' '), '_', $folder);
$folder = $this->browseBase . $this->currentDirectory . $folder;
if (is_dir($folder))
{
$this->view->error('error_folder_already_exists', basename($folder));
return;
}
if (!mkdir($folder))
{
$this->view->error('error_unknown');
}
$this->view->success('success_folder_created', basename($folder));
chmod($folder, 0777);
return;
}
function deleteFolder() {
$folder = $this->browseBase . $this->currentDirectory . basename($_POST['folder']);
if (!rmdir($folder)) {
$this->view->error('error_not_deleted', basename($folder));
return;
}
$this->view->success('success_deleted', basename($folder));
return;
}
function renameFile() {
$newName = str_replace(array('..', '<', '>', ':', '?'), '', basename($_POST['renameFile']));
$newName = str_replace(array(' ', ' ', ' ', ' ', ' '), '_', $newName);
$oldName = $_POST['oldName'];
if ($oldName == $newName) {
return;
}
if (pathinfo($newName, PATHINFO_EXTENSION) !== pathinfo($oldName, PATHINFO_EXTENSION)) {
$this->view->message = 'You can not change the file extension!';
return;
}
if (file_exists($this->browseBase . $this->currentDirectory . '/' . $newName)) {
$this->view->error('error_file_already_exists', $newName);
return;
}
if (is_array($this->fileIsLinked($oldName))) {
$this->view->error('error_cant_rename', $oldName);
$this->view->error('error_file_is_used', $oldName);
foreach ($this->fileIsLinked($oldName) as $page) {
$this->view->message .= '<li>' . $page . '</li>';
}
$this->view->message .= '</ul>';
return;
}
if (rename($this->browseBase . $this->currentDirectory . '/' . $oldName, $this->browseBase . $this->currentDirectory . '/' . $newName)) {
$this->view->message = 'Renamed ' . $oldName . ' to ' . $newName . '!';
return;
}
$this->view->message = 'Something went wrong (CMSimpleFileBrowser::renameFile())';
return;
}
function render($template) {
$template = str_replace(array('.', '/', '\\', '<', ' '), '', $template);
if (!file_exists($this->browserPath . 'tpl/' . $template . '.html')) {
return "<p>CMSimpleFileBrowser::render() - Template not found: {$this->browserPath}tpl/$template.html'</p>";
}
$this->view->baseDirectory = $this->baseDirectory;
// $this->view->basePath = '';
$this->view->baseLink = $this->linkType;
$this->view->folders = $this->foldersArray();
$this->view->subfolders = $this->folders;
$this->view->files = $this->files;
return $this->view->loadTemplate($this->browserPath . 'tpl/' . $template . '.html');
}
function setLinkParams($paramsString) {
$this->view->linkParams = $paramsString;
}
function setLinkPrefix($prefix) {
$this->view->linkPrefix = $prefix;
}
function setBrowseBase($path) {
$this->browseBase = $path;
$this->view->basePath = $path;
}
function setBrowserPath($path) {
$this->view->browserPath = $path;
}
function setMaxFileSize($folder = '', $bytes = 0) {
if (key_exists($folder, $this->baseDirectories)){
$this->maxFilesizes[$folder] = (int) $bytes;
}
}
}
?>

View File

@ -0,0 +1,535 @@
<?php
if (preg_match('#/filebrowser/classes/filebrowser_view.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
/* utf-8 marker: äöü */
class CMSimpleFileBrowserView
{
var $partials = array();
var $browserPath = '';
var $basePath;
var $baseDirectory;
var $baseLink;
var $currentDirectory;
var $linkParams;
var $linkPrefix;
var $folders;
var $subfolders;
var $files;
var $message = '';
var $lang = array();
function __construct()
{
global $sl, $pth, $plugin_tx, $tx;
$lang = array();
// Own language files for subsites
if(file_exists('./languages/' . basename($sl) . '.php'))
{
$langFile = './languages/';
}
else
{
$langFile = $pth['folder']['cmsimple'] . 'languages/';
}
$langFile .= file_exists($langFile . $sl . '.php') ? $sl . '.php' : 'en.php';
include_once $langFile;
$this->lang = $tx['filebrowser'];
}
function folderList($folders)
{
global $tx, $plugin_tx, $adm, $subsite_folder;
// $title = $this->baseLink === 'images' ? 'Bilder' : 'Downloads';
if($adm == '')
{
$title = ucfirst($tx['title'][$this->baseLink]) ? $tx['title'][$this->baseLink] : ucfirst($tx['title']['userfiles'] . ' ' . $this->translate('folder')); // für Editorbrowser
}
else
{
$title = ucfirst($tx['title'][$this->baseLink]) ? $tx['title']['userfiles'] : ucfirst($tx['title']['userfiles'] . ' ' . $this->translate('folder')); // für CMS Browser
}
$html = '
<ul>
<li class="openFolder">
<a href="?' . $this->linkParams . '">' . $title . ' ' . $tx['filebrowser']['folder'] . '</a>
<ul>';
foreach ($folders as $folder => $data)
{
if ($data['level'] == 2)
{
$html .= $data['linkList'];
}
}
$html .='
</ul>
</li>
</ul>';
return $html;
}
function folderLink($folder, $folders)
{
global $subsite_folder;
$link = $_SESSION['fb_sn'];
if(!defined('CMSIMPLE_VERSION'))
{
$link = str_replace($_SESSION['subsite_folder'],'',$_SESSION['fb_sn']);
$link.='plugins/filebrowser/editorbrowser.php';
}
$class = 'folder';
if (substr($this->currentDirectory, 0, strlen($folder)) == $folder)
{
$class = 'openFolder';
}
$temp = explode('/', $folder);
$html = "\n" . '
<li class="' . $class . '">
<a href="?' . $this->linkParams . '&subdir=' . $folder . '/">' . end($temp) . '</a>';
if (count($folders[$folder]['children']) > 0)
{
if (substr($this->currentDirectory, 0, strlen($folder)) !== $folder)
{
$class = 'unseen';
}
$html .= '
<ul class="' . $class . '">';
foreach ($folders[$folder]['children'] as $child)
{
$html .= $this->folderLink($child, $folders);
}
$html .= '
</ul>';
}
$html .= '
</li>';
return $html;
}
function subfolderList($folders)
{
global $csrfSession;
$html = '';
if (is_array($folders) && count($folders) > 0)
{
$html = '<ul>';
foreach ($folders as $folder)
{
$name = str_replace($this->currentDirectory, '', $folder);
$html .= '
<li class="folder">
<form style="display: inline;" method="POST" action="" onsubmit="return confirmFolderDelete(\'' . $this->translate('confirm_delete', $this->basePath . $folder) . '\');">
<input type="hidden" name="csrf_token" value="' . $_SESSION['csrf_token' . $_SESSION['fb_snForCsrf']] . '">
<input type="image" src="' . $this->browserPath . 'icons/delete.gif" alt="delete" title="delete folder" style="float: left; margin-right: 8px;" />
<input type="hidden" name="deleteFolder" />
<input type="hidden" name="folder" value="' . $folder . '" />
</form>
<a href="?' . $this->linkParams . '&subdir=' . $folder . '/">' . $name . '</a></li>';
}
$html .= '</ul>
';
}
return $html;
}
function fileList($files)
{
global $cf, $images, $csrfSession;
if(isset($_SESSION['fb_view']) && $_SESSION['fb_view'] == 'list')
{
$html = '
<ul class="fb_files_list">';
}
else
{
$html = '
<ul>';
}
$i = 0;
foreach ($files as $file)
{
if(isset($_SESSION['fb_view']) && $_SESSION['fb_view'] == 'miniatur' || !isset($_SESSION['fb_view'])) // thumbs view
{
$html.= '
<li style="width: ' . ($cf['filebrowser']['maxheight_of_thumbs']+$cf['filebrowser']['width_px_plus']) . 'px; height: ' . ($cf['filebrowser']['maxheight_of_thumbs']+66) . 'px; padding: 8px 0 12px 8px; margin: 6px 3px 9px 3px;">
<form style="display: inline;" method="POST" action="" onsubmit="return confirmFileDelete(\'' . $this->translate('confirm_delete', $this->currentDirectory . $file) . '\');">
<input type="hidden" name="csrf_token" value="' . $_SESSION[$csrfSession] . '">
<input type="image" src="' . $this->browserPath . 'icons/delete.gif" alt="delete" title="delete file" style="float: left; margin-right: 8px;" />
<input type="hidden" name="deleteFile" />
<input type="hidden" name="file" value="' . $file . '" />
</form>
<form method="POST" style="display:none;" action="" id="rename_' . $i . '">
<input type="hidden" name="csrf_token" value="' . $_SESSION[$csrfSession] . '">
<input type="text" size="25" name="renameFile" value="' . $file . '" onmouseout="hideRenameForm(\'' . $i . '\');"/>
<input type="hidden" name="oldName" value="' . $file . '" />
</form>
<a style="position:relative" class="cmsimplefbfile" href="javascript:void(0)" id="file_' . $i . '" ondblclick="showRenameForm(\'' . $i . '\', \'' . $this->translate('prompt_rename', $file) . '\');" title="' . $file . '">
<div style="clear: both; width: 240px; float: left; padding-top: 6px;">' . substr($file,0,14);
if(strlen($file) > 14 )
{
$html.= '...';
}
$html.= '</div>';
if
(
mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/gif'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/jpeg'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/png'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/tiff'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/bmp'
)
{
$image = getimagesize($this->basePath . $this->currentDirectory . $file);
$width = $image[0];
$height = $image[1];
if ($width > 100)
{
$ratio = $width / $height;
$width = 100;
$height = $width / $ratio;
}
}
$fbFileTypeArray = explode('.',$file);
$fbFileType = array_pop($fbFileTypeArray);
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '<span class="filebrowser_image"><img src="' . $this->basePath . $this->currentDirectory . $file . '" style="float: left; max-width: 92%; max-height: ' . $cf['filebrowser']['maxheight_of_thumbs'] . 'px; padding: 0; margin: 0;" alt="' . $file . '" /></span>';
}
else
{
$html.= '<div class="fb_dummy" style="line-height: 2.4em;">' . $fbFileType . '</div>';
}
$html .= '
</a>
<p style="clear: both; padding: 6px 0 0 0; margin: 0; font-size: 12px;">
' . round(filesize($this->basePath . $this->currentDirectory . $file) / 1024, 0) . '&nbsp;kb';
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '&nbsp;/&nbsp;' . $image[0] . '&nbsp;x&nbsp;' . $image[1];
}
$html .= '</p>
</li>
';
}
if(isset($_SESSION['fb_view']) && $_SESSION['fb_view'] == 'list') // list view
{
$html .= '
<li class="fb_file">
<form style="display: inline;" method="POST" action="" onsubmit="return confirmFileDelete(\'' . $this->translate('confirm_delete', $this->currentDirectory . $file) . '\');">
<input type="hidden" name="csrf_token" value="' . $_SESSION[$csrfSession] . '">
<input type="image" src="' . $this->browserPath . 'icons/delete.gif" alt="delete" title="delete file" style="margin-right: 8px;" />
<input type="hidden" name="deleteFile" />
<input type="hidden" name="file" value="' . $file . '" />
</form>
<form method="POST" style="display:none;" action="" id="rename_' . $i . '">
<input type="hidden" name="csrf_token" value="' . $_SESSION[$csrfSession] . '">
<input type="text" size="25" name="renameFile" value="' . $file . '" onmouseout="hideRenameForm(\'' . $i . '\');"/>
<input type="hidden" name="oldName" value="' . $file . '" />
</form>
<a style="position:relative" class="cmsimplefbfile" href="javascript:void(0)" id="file_' . $i . '" ondblclick="showRenameForm(\'' . $i . '\', \'' . $this->translate('prompt_rename', $file) . '\');" title="' . $file . '">' . substr($file,0,18);
if(strlen($file) > 18 )
{
$html.= '...';
}
if
(
mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/gif'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/jpeg'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/png'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/tiff'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/bmp'
)
{
$image = getimagesize($this->basePath . $this->currentDirectory . $file);
$width = $image[0];
$height = $image[1];
if ($width > 100)
{
$ratio = $width / $height;
$width = 100;
$height = $width / $ratio;
}
}
$fbFileTypeArray = explode('.',$file);
$fbFileType = array_pop($fbFileTypeArray);
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '<span class="filebrowser_image"><img src="' . $this->basePath . $this->currentDirectory . $file . '" style="max-height: ' . $cf['filebrowser']['maxheight_of_thumbs'] . 'px; padding: 0; margin: 0;" alt="' . $file . '" title="' . $file . '" /></span>';
}
$html .= '
</a>
<span class="fb_filedata"> - <span style="font-family: tahoma, verdana, arial, sans-serif; font-weight: 700; padding: 0;">' . $fbFileType . '</span> - ' . round(filesize($this->basePath . $this->currentDirectory . $file) / 1024, 0) . '&nbsp;kb';
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '&nbsp;/&nbsp;' . $image[0] . '&nbsp;x&nbsp;' . $image[1];
}
$html .= '</span>
</li>
';
}
$i++;
}
$html .= '<br style="clear: both;"></ul>
<div style="clear: both; padding: 36px;">&nbsp;</div>';
return $html;
}
function fileListForEditor($files)
{
global $cf;
if(isset($_SESSION['fb_view']) && $_SESSION['fb_view'] == 'list')
{
$html = '
<ul class="fb_files_list">';
}
else
{
$html = '
<ul>';
}
$dir = $this->basePath . $this->currentDirectory;
$is_image = (int) (strpos($this->linkParams, 'type=images') === 0);
foreach ($files as $file)
{
if // thumbs view
(
(isset($_SESSION['fb_view']) && $_SESSION['fb_view'] == 'miniatur' || !isset($_SESSION['fb_view']))
)
{
$html .= '
<li style="';
$html .= 'width: ' . ($cf['filebrowser']['maxheight_of_thumbs']+$cf['filebrowser']['width_px_plus']) . 'px; height: ' . ($cf['filebrowser']['maxheight_of_thumbs']+60) . 'px; padding: 8px 0 12px 8px; margin: 6px 3px 9px 3px;">';
$prefix = $this->linkPrefix;
if ($prefix != '?&amp;download=')
{
$prefix .= $this->currentDirectory;
}
$html .= '<a href="#" class="cmsimplefbfile" onclick="window.setLink(\'' . $prefix . $file . '\',' . $is_image . '); return false;" title="' . $file . '">' . substr($file,0,14);
if(strlen($file) > 14 )
{
$html.= '...';
}
if
(
mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/gif'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/jpeg'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/png'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/tiff'
|| mime_content_type($this->basePath . $this->currentDirectory . $file) == 'image/bmp'
)
{
$image = getimagesize($this->basePath . $this->currentDirectory . $file);
$width = $image[0];
$height = $image[1];
if ($width > 100)
{
$ratio = $width / $height;
$width = 100;
$height = $width / $ratio;
}
}
$fbFileTypeArray = explode('.',$file);
$fbFileType = array_pop($fbFileTypeArray);
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '<span class="filebrowser_image"><img src="' . $this->basePath . $this->currentDirectory . $file . '" style="float: left; max-width: 92%; max-height: ' . $cf['filebrowser']['maxheight_of_thumbs'] . 'px; padding: 0; margin: 0;" alt="' . $file . '" title="' . $file . '" /></span>';
}
else
{
$html.= '<div class="fb_dummy" style="line-height: 2.4em;">' . $fbFileType . '</div>';
}
$html .= '
</a>
<p style="clear: both; padding: 6px 0 0 0; margin: 0; font-size: 12px;">
' . round(filesize($this->basePath . $this->currentDirectory . $file) / 1024, 0) . '&nbsp;kb';
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '&nbsp;/&nbsp;' . $image[0] . '&nbsp;x&nbsp;' . $image[1];
}
$html .= '</p>';
$html .= '</li>';
}
else // list view
{
$html .= '
<li class="fb_file" style="';
$html .= 'width: 90%; background: transparent; border: 0;">';
$prefix = $this->linkPrefix;
if ($prefix != '?&amp;download=')
{
$prefix .= $this->currentDirectory;
}
$html .= '<a href="#" class="cmsimplefbfile" onclick="window.setLink(\'' . $prefix . $file . '\',' . $is_image . '); return false;" title="' . $file . '">' . substr($file,0,18);
if(strlen($file) > 18 )
{
$html.= '...';
}
if ((strpos($this->linkParams, 'type=images') !== FALSE && getimagesize($dir . $file)) || preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$image = getimagesize($dir . $file);
$width = $image[0];
$height = $image[1];
if ($width > 150)
{
$ratio = $width / $height;
$width = 150;
$height = $width / $ratio;
}
}
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '<span style="position: relative; z-index: 4; width: 100%; text-align: center;">
<img src="' . $this->basePath . $this->currentDirectory . $file . '" style="max-height: ' . $cf['filebrowser']['maxheight_of_thumbs'] . 'px;" alt="' . $file . '" title="' . $file . '" /></span>';
}
$fbFileTypeArray = explode('.',$file);
$fbFileType = array_pop($fbFileTypeArray);
$html .= '
</a>
<span class="fb_filedata"> - <span style="font-family: tahoma, verdana, arial, sans-serif; font-weight: 700; padding: 0;">' . $fbFileType . '</span> - ' . round(filesize($this->basePath . $this->currentDirectory . $file) / 1024, 0) . '&nbsp;kb';
if(preg_match('/.jpg|.jpeg|.png|.webp|.gif/i',$file))
{
$html .= '&nbsp;/&nbsp;' . $image[0] . '&nbsp;x&nbsp;' . $image[1];
}
$html .= '</span>
</li>
';
} // END else
} // END foreach
$html .= '</ul>';
return $html;
}
function loadTemplate($template)
{
global $csrfSession;
if (file_exists($template))
{
ob_start();
global $tx;
include $template;
}
$html = ob_get_clean();
$this->partials['folders'] = $this->folderList($this->folders);
$this->partials['subfolders'] = $this->subFolderList($this->subfolders);
if (basename($template) == 'cmsbrowser.html')
{
$this->partials['files'] = $this->fileList($this->files);
}
if (basename($template) == 'editorbrowser.html')
{
$this->partials['files'] = $this->fileListForEditor($this->files);
}
$this->partials['message'] = $this->message;
foreach ($this->partials as $placeholder => $value)
{
$html = str_replace('%' . strtoupper($placeholder) . '%', $value, $html);
}
$this->message = '';
return $html;
}
function error($message ='', $args = null)
{
global $tx;
$this->message .= $this->translate($message, $args);
}
function success($message, $args = null)
{
global $tx;
$this->message .= '<p style="width: auto;">' . $this->translate($message, $args) . '</p>';
}
function message($message)
{
$this->message .= '<p style="width: auto;">' . $message . '</p>';
}
function translate($string = '', $args = null)
{
if (strlen($string) === 0)
{
return '';
}
$html = '';
if (!isset($this->lang[$string]))
{
$html = '{' . $string . '}';
}
else
{
$html = $this->lang[$string];
}
//
if (is_array($args))
{
array_unshift($args, $html);
return call_user_func_array('sprintf', $args);
}
if (is_string($args))
{
$html = sprintf($html, $args);
return $html;
}
return $html;
}
}
?>

View File

@ -0,0 +1,13 @@
<?php
/* utf-8 marker: äöü */
if (!defined('CMSIMPLE_VERSION') || preg_match('#/filebrowser/classes/required_classes.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
global $pth;
require_once $pth['folder']['plugin'] . 'classes/filebrowser_view.php';
require_once $pth['folder']['plugin'] . 'classes/filebrowser.php';
?>

View File

@ -0,0 +1,86 @@
<?php /* utf-8 marker: äöü */
require_once './classes/filebrowser_view.php';
require_once './classes/filebrowser.php';
global $cf;
include ('../../cmsimple/config.php');
if (!isset($_SESSION)) { session_start(); }
//if(!isset($_SESSION['fb_sn']))die('fatal error');
//echo 'https://' . $_SERVER['SERVER_NAME'] . $_SERVER['SCRIPT_NAME'];
if(isset($_SESSION['fb_sn']))$fbsn = $_SESSION['fb_sn'];
$fb_access = FALSE;
if (isset($_SESSION['fb_sn']) && $_SESSION['fb_session'] === session_id()) $fb_access = TRUE;
if ($fb_access === FALSE) die('no access');
$base = './../../';
$browser = $_SESSION['fb_browser'];
$browser->setBrowseBase($base);
//$_GET['base'] = isset($_GET['base']) ? str_replace(array('../', './', '<', '>', '(', ')', ';', ':'), '', $_GET['base']) : '';
//$_SESSION['fb_browse_base'] = $_GET['base'];
if (isset($_GET['type']) && $_GET['type'] === 'file') $_GET['prefix'] = '?&amp;download=';
//$my_prefix = $_GET['type'] === 'file' ? '?&amp;download=' : $_GET['prefix'];
//var_dump($_SESSION);
$fb_type = null;
if (isset($_GET['type']))
{
$fb_type = $_GET['type'];
if ($fb_type == 'image') {$fb_type = 'images';}
if ($fb_type == 'file') {$fb_type = 'downloads';}
}
if ($fb_type && array_key_exists($fb_type, $browser->baseDirectories)) {
$browser->linkType = $fb_type;
if(isset($_GET['prefix'])){$browser->setLinkPrefix($_GET['prefix']);}
$browser->linkType = $fb_type;
$src = $_GET;
$src['type'] = $fb_type;
unset($src['subdir']);
// the following is a simplyfied http_build_query()
$dst = array();
foreach ($src as $key => $val) {$dst[] = urlencode($key) . '=' . urlencode($val);}
$dst = implode('&', $dst);
$browser->setlinkParams($dst);
$browser->baseDirectory = $browser->baseDirectories[$fb_type];
$browser->currentDirectory = $browser->baseDirectories[$fb_type];
if (isset($_GET['subdir'])) {
$subdir = str_replace(array('../', './', '?', '<', '>', ':'), '', $_GET['subdir']);
if (strpos($subdir, $browser->currentDirectory) === 0) {
$browser->currentDirectory = rtrim($subdir, '/') . '/';
}
}
if (isset($_POST['upload']))$browser->uploadFile();
if (isset($_POST['createFolder']))$browser->createFolder();
if (isset($_POST['renameFile']))$browser->renameFile();
$browser->readDirectory();
if(isset($_GET['editor']))$jsFile = 'editorhooks/' . basename($_GET['editor']) . '/script.php';
$script = 'xxx';
if (isset($jsFile) && file_exists($jsFile)) include $jsFile;
$test = '';
//$test .= print_r($_SERVER, true);
$browser->view->partials['script'] = $script;
$browser->view->partials['test'] = $test;
$browser->browserPath = '';
echo $browser->render('editorbrowser');
}
else die('fatal error');
?>

View File

@ -0,0 +1,15 @@
<?php
/* utf-8 marker: äöü */
/* script.php build: 2011012801 */
$script = '
<script language="javascript" type="text/javascript">
function setLink(link){
//window.opener.CKEDITOR.tools.callFunction( 2, link );
window.opener.CKEDITOR.tools.callFunction('.$_GET['CKEditorFuncNum'].', link );
window.close();
}
</script>
';
?>

View File

@ -0,0 +1,13 @@
<?php
/* utf-8 marker: äöü */
if($s < 0){ return '';}
$script = file_get_contents(dirname(__FILE__) . '/tinymce.js');
$base = CMSIMPLE_ROOT . 'plugins/';
$prefix = CMSIMPLE_BASE;
$script = str_replace('%URL%', $base . 'filebrowser/editorbrowser.php?editor=tinymce&prefix='. $prefix .'&base=./&level=' . $l[$s], $script);
return $script;
/*
* end of plugins/wr_filebrowser/tinymce.php
*/
?>

View File

@ -0,0 +1,34 @@
<?php
$script = '
<script>
var FileBrowserDialogue = {
init : function () {
// Nothing to do
},
submit : function (url) {
var URL = url;
var args = top.tinymce.activeEditor.windowManager.getParams();
var win = args.window;
var input = win.document.getElementById(args.input);
input.value = URL;
if (input.onchange) input.onchange(); //??? falls noch ein anderer trigger ???
top.tinymce.activeEditor.windowManager.close();
}
}
function setLink(link){
FileBrowserDialogue.submit(link);
return true;
}
</script>';
?>

View File

@ -0,0 +1,33 @@
function wrFilebrowser (field_name, url, type, win) {
poppedUpWin = win;
inputField = field_name;
// alert("Field_Name: " + field_name + "nURL: " + url + "nType: " + type + "nWin: " + win); // debug/testing
var cmsURL = "%URL%";
if (cmsURL.indexOf("?") < 0) {
cmsURL = cmsURL + "?type="+ type ;
}
else {
cmsURL = cmsURL + "&type="+type ;
}
tinyMCE.activeEditor.windowManager.open(
{
file : cmsURL,
width : 800,
height : 600,
resizable : "yes",
inline : "yes",
close_previous : "no",
popup_css : false
},
{
window : win,
input : field_name
}
);
return false;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 656 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 781 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 961 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 961 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 989 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 625 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 905 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 581 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 848 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 581 B

View File

@ -0,0 +1,85 @@
<?php
if (!defined('CMSIMPLE_VERSION') || preg_match('#/filebrowser/index.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
/* utf-8 marker: äöü */
if(!$adm) {return true;}
if(!isset($_SESSION)){session_start();}
$temp = './';
$editor_fb = new CMSimpleFileBrowser();
$editor_fb->setBrowseBase(CMSIMPLE_BASE);
$editor_fb->setBrowserPath($pth['folder']['plugins'] . 'filebrowser/');
$editor_fb->setMaxFileSize('images', $cf['images']['maxsize']);
$editor_fb->setMaxFileSize('downloads', $cf['downloads']['maxsize']);
$_SESSION['fb_browser'] = $editor_fb;
$_SESSION['fb_session'] = session_id();
$_SESSION['fb_sn'] = $sn;
$_SESSION['fb_sl'] = $sl;
$_SESSION['fb_snForCsrf'] = $snForCsrf;
if($subsite_folder == '/')
{
$_SESSION['subsite_folder'] = '';
}
else
{
$_SESSION['subsite_folder'] = $subsite_folder;
}
if($pth['folder']['base'] != './' && !is_writable('./userfiles'))
{
$_SESSION['subsite_folder_link'] = $subsite_folder;
}
else
{
$_SESSION['subsite_folder_link'] = '';
}
if(is_writable('./userfiles'))
{
$_SESSION['subsite_folder_userfiles'] = $_SESSION['fb_sn'];
}
else
{
if(CMSIMPLE_ROOT != '/')
{
$_SESSION['subsite_folder_userfiles'] = CMSIMPLE_ROOT;
}
else
{
$_SESSION['subsite_folder_userfiles'] = '';
}
}
// outcomment following lines for development only
//echo '$_SESSION[\'subsite_folder\']: ' . $_SESSION['subsite_folder'] . '<br>';
//echo '$_SESSION[\'subsite_folder_userfiles\']: ' . $_SESSION['subsite_folder_userfiles'] . '<br>';
/*
if(is_writable('./userfiles'))
{
echo 'userfiles folder writable<br><br>';
}
else
{
echo 'userfiles folder <b>NOT</b> writable<br><br>';
}
echo '$subsite_folder : ' . $subsite_folder . '<br>';
echo '$_SESSION[\'fb_sn\'] : ' . $_SESSION['fb_sn'] . '<br>';
echo '$_SESSION[\'subsite_folder\'] : ' . $_SESSION['subsite_folder'] . '<br>';
echo '$_SESSION[\'subsite_folder_link\'] : ' . $_SESSION['subsite_folder_link'] . '<br>';
echo '$_SESSION[\'subsite_folder_userfiles\'] : ' . $_SESSION['subsite_folder_userfiles'] . '<br>';
echo 'CMSIMPLE_ROOT : ' . CMSIMPLE_ROOT . '<br>';
*/
?>

View File

@ -0,0 +1,55 @@
function confirmFileDelete(string)
{
return confirm(string);
}
function confirmFolderDelete(string)
{
return confirm(string);
}
function showcmsimplefbForm(id)
{
forms = document.getElementsByTagName('fieldset');
for(i=0; i<forms.length; i++){
form = forms[i];
if(form.className == "cmsimplefbform"){
form.style.display='none';
}
}
document.getElementById(id).style.display='block';
document.getElementById(id).getElementsByTagName('input')[0].focus();
}
function closecmsimplefbForm(id)
{
document.getElementById(id).style.display='none';
}
function oldshowRenameForm(id)
{
document.getElementById("rename_" + id).style.display='inline';
document.getElementById("rename_" + id).renameFile.select();
document.getElementById("file_" + id).style.display='none';
}
function showRenameForm(id, message)
{ var oldName = document.getElementById("rename_" + id).renameFile.value;
var newName = prompt(message, oldName);
if(newName){
// document.getElementById("rename_" + id).style.display='inline';
document.getElementById("rename_" + id).renameFile.value=newName;
document.getElementById("rename_" + id).submit();
}
}
function hideRenameForm(id)
{
document.getElementById("rename_" + id).style.display='none';
document.getElementById("file_" + id).style.display='inline';
}

View File

@ -0,0 +1,92 @@
<?php global $tx, $csrfSession; ?>
<!--utf-8 marker: äöü -->
<?php
if(@$_POST['fb_viewSelect'])
{
csrfProtection();
$_SESSION['fb_view'] = $_POST['fb_viewSelect'];
}
echo '<form method="post" action="#">
<input type="hidden" name="csrf_token" value="' . $_SESSION[$csrfSession] . '">
<select name="fb_viewSelect" style="float: right; width: 160px; background: #fff; border: 2px solid #c60; padding: 2px; margin: 6px 3px 0 0;" onchange="this.form.submit()">
<option value="list" style="padding: 0 6px;"';
if(@$_SESSION['fb_view'] == 'list')
{
echo ' selected="selected"';
}
echo '>' . $tx['filebrowser']['view_list'] . '</option>
<option value="miniatur" style="padding: 0 6px;"';
if((@$_SESSION['fb_view'] == 'miniatur' || !isset($_SESSION['fb_view'])))
{
echo ' selected="selected"';
}
echo '>' . $tx['filebrowser']['view_thumbs'] . '</option>
</select>
<noscript><input type="submit" value="Submit" /></noscript>
</form>
<div style="clear: both;"></div>';
?>
<table style="width: 100%;">
<tr>
<td style="width: 20%; min-width: 280px; vertical-align: top;">
<div id="CMSimpleFileBrowserMenu">
<div id="folders">
%FOLDERS%
</div>
</div>
</td>
<td style="vertical-align: top;">
<div id="CMSimpleFileBrowser" style="padding: 0 10px!important;">
<div id="subfolders">
<div style="clear: both; margin: 0 0 10px 0;">
<p>
<?php echo '<b>' . $tx['filetype']['folder'] . ': &nbsp; <span style="white-space: nowrap; color: #c00; font-family: courier new, monospace; font-size: 16px;">' . $_SERVER['SERVER_NAME'] . str_replace($_SESSION['subsite_folder_link'],'',$_SESSION['fb_sn']) . '</span></b> <span style="white-space: nowrap; font-family: courier new, monospace; font-size: 16px;">' . str_replace($_SESSION['subsite_folder'],'',$this->currentDirectory) . '</span>'; ?>
</p>
<b><a href="javascript:void();" onClick="window.showcmsimplefbForm('cmsimplefbCreateDir');"><?php echo '=> ' . $this->translate('create_folder'); ?></a></b>
</div>
<fieldset id="cmsimplefbCreateDir" class="cmsimplefbform">
<legend><?php echo $this->translate('create_subfolder_in', $this->currentDirectory); ?> <a href="javascript:window.closecmsimplefbForm('cmsimplefbCreateDir');"><b>[ x ]</b></a></legend>
<div style="padding: 14px 10px;">
<form method="POST" action="">
<input type="hidden" name="csrf_token" value="<?php echo $_SESSION[$csrfSession];?>">
<input type="text" style="max-width: 240px;" name="createFolder" size="30" />
<input type="submit" class="submit" value="<?php echo $this->translate('create_folder'); ?>" />
</form>
</div>
</fieldset>
%SUBFOLDERS%
</div>
<hr />
<div id="files">
<div style="font-weight: 700; margin-bottom: 12px;">
<?php echo $this->translate('files');?> &nbsp; <a href="javascript:window.showcmsimplefbForm('cmsimplefbUploadFile');"> =&gt; <?php echo $this->translate('upload_file'); ?></a>
</div>
<fieldset id="cmsimplefbUploadFile" class="cmsimplefbform">
<legend><?php echo $this->translate('upload_file_to', $this->currentDirectory); ?> <a href="javascript:window.closecmsimplefbForm('cmsimplefbUploadFile');"><b>[ x ]</b></a></legend>
<div style="padding: 4px 10px;">
<form method="POST" action="" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="<?php echo $_SESSION[$csrfSession];?>">
<p><input type="file" name="fbupload" style="float: left;" /></p><br />
<input type="hidden" name="upload" value="upload" />
<p><input type="submit" class="submit" value="<?php echo $this->translate('upload_file'); ?>" /></p>
</form>
</div>
</fieldset>
<p style="font-size: 14px;"><?php echo $this->translate('files_rename');?></p>
%MESSAGE%
%FILES%
</div>
</div>
</td>
</tr>
</table>
<div style="clear:both;"></div>

View File

@ -0,0 +1,101 @@
<!DOCTYPE html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Filebrowser</title>
<link rel="stylesheet" href="../../css/core.css" type="text/css">
<style>body {padding: 0; margin: 0; overflow: auto;}</style>
%SCRIPT%
<script type="text/javascript" src="./js/filebrowser.js"></script>
</head>
<body>
<!--utf-8 marker: äöü -->
<?php
@session_start();
include('../../cmsimple/languages/' . $_SESSION['fb_sl'] . '.php');
if(@$_POST['fb_viewSelect'])
{
$_SESSION['fb_view'] = $_POST['fb_viewSelect'];
}
echo '<form method="post" action="#">
<input type="hidden" name="csrf_token" value="' . $_SESSION['csrf_token' . $_SESSION['fb_snForCsrf']] . '">
<select name="fb_viewSelect" style="float: right; width: 160px; border: 2px solid #c60; padding: 2px; margin: 6px 3px 0 0;" onchange="this.form.submit()">
<option value="list" style="padding: 0 6px;"';
if(@$_SESSION['fb_view'] == 'list')
{
echo ' selected="selected"';
}
echo '>' . $tx['filebrowser']['view_list'] . '</option>
<option value="miniatur" style="padding: 0 6px;"';
if((@$_SESSION['fb_view'] == 'miniatur' || !isset($_SESSION['fb_view'])))
{
echo ' selected="selected"';
}
echo '>' . $tx['filebrowser']['view_thumbs'] . '</option>
</select>
<noscript><input type="submit" value="Submit"></noscript>
</form>
<div style="clear: both;"></div>';
?>
<div style="position: absolute; width: 100%; height: 90%; overflow: scroll; border: 0px solid #080;">
<div id="CMSimpleFileBrowserMenu">
<?php echo $tx['filetype']['folder'] . ': &nbsp; <span style="white-space: nowrap; color: #c00; font-family: courier new, monospace; font-size: 12px;">' . $_SERVER['SERVER_NAME'] . str_replace($_SESSION['subsite_folder_link'],'',$_SESSION['fb_sn']) . '</span> <span style="white-space: nowrap; font-family: courier new, monospace; font-size: 12px;">' . str_replace($_SESSION['subsite_folder'],'',$this->currentDirectory) . '</span>'; ?><br>
<a href="#" onClick="window.showcmsimplefbForm('cmsimplefbCreateDir');"><?php echo $this->translate('create_folder'); ?></a> |
<a href="#" onClick="window.showcmsimplefbForm('cmsimplefbUploadFile');"><?php echo $this->translate('upload_file'); ?></a>
<fieldset id="cmsimplefbUploadFile" class="cmsimplefbform">
<legend><?php echo $this->translate('upload_file_to', $this->currentDirectory); ?> <a href="#" onClick="window.closecmsimplefbForm('cmsimplefbUploadFile');">[x]</a></legend>
<div style="padding: 20px 30px;">
<form method="POST" action="" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="<?php echo $_SESSION['csrf_token' . $_SESSION['fb_snForCsrf']];?>">
<input type="file" name="fbupload">
<input type="hidden" name="upload" value="upload">
<input type="submit" class="submit" value="<?php echo $this->translate('upload_file'); ?>">
</form>
</div>
</fieldset>
<fieldset id="cmsimplefbCreateDir" class="cmsimplefbform">
<legend><?php echo $this->translate('create_subfolder_in', $this->currentDirectory); ?> <a href="#" onClick="window.closecmsimplefbForm('cmsimplefbCreateDir');">[x]</a></legend>
<div style="padding: 20px 30px;">
<form method="POST" action="">
<input type="hidden" name="csrf_token" value="<?php echo $_SESSION['csrf_token' . $_SESSION['fb_snForCsrf']];?>">
<input type="text" name="createFolder" size="30">
<input type="submit" class="submit" value="<?php echo $this->translate('create_folder'); ?>">
</form>
</div>
</fieldset>
</div>
<div id="CMSimpleFileBrowser">
<table style="width: 100%;">
<tr>
<td style="width: 20%; min-width: 200px; vertical-align: top;">
<div id="folders" style="width: 100%; overflow: hidden;">
%FOLDERS%
</div>
</td>
<td style="vertical-align: top;">
<div id="files" style="overflow: auto; z-index: 3; font-weight: 300; padding: 0 6px 100px 16px;">
<span class="cmsimplefb_files"><?php echo $this->translate('files');?></span><br>
%MESSAGE%
%FILES%
</div>
</td>
</tr>
</table>
<div style="clear:both;"></div>
</div>
</div>
</body>
</html>

1125
cms/plugins/index.php Normal file

File diff suppressed because it is too large Load Diff

278
cms/plugins/jquery/GPL2.txt Normal file
View File

@ -0,0 +1,278 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Lesser General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

View File

@ -0,0 +1,34 @@
<?php // utf8-marker: äöü
if (!defined('CMSIMPLE_VERSION') || preg_match('#/jquery/admin.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
/*
=========================================================
Adapted for CMSimple 4.0 and higher:
Gert Ebersbach 2013
ge-webdesign.de
=========================================================
based on "jQuery for CMSimple" version 1.3 2011-07-27
author: Holger Irmler - cmsimple.holgerirmler.de
*/
initvar('jquery');
if($jquery)
{
$o.= '<div class="plugintext">
<div class="plugineditcaption">
Plugin jQuery for CMSimple
</div>
<hr />
<p>' . $tx['message']['plugin_standard1'] . '</p>
<p>' . $tx['message']['plugin_standard2'] . ' <a href="./?file=config&amp;action=array"><b>' . $tx['filetype']['config'] . '</b></a></p>
<hr />
<p>based on jQuery for CMSimple v. 1.3.1</p>' .
'<p>Author: &copy; 2011 <a href="http://cmsimple.holgerirmler.de/" target="_blank">Holger Irmler</a></p>
<p>Adapted for CMSimple 4.0 and higher by <a href="http://www.ge-webdesign.de/" target="_blank">ge-webdesign.de</a></p>
</div>';
}
?>

View File

@ -0,0 +1,36 @@
Legend
------------------------------------------------------------------------------------------------------------------
first line: date / author
* = filename / package => new version-nr.
:> = old code
=> = new code
+> = added code
-> = deleted code
x> = general changes
------------------------------------------------------------------------------------------------------------------
Version 1.3.1 Build 2011093001
jQuery updated to version 1.6.4
jQuery UI updated to version 1.8.16
Help-File updated: added "global $plugin_cf" to code examples
------------------------------------------------------------------------------------------------------------------
Version 1.3 Build 2011072701
* jquery.inc.php:
load jQuery always as first library:
:> $hjs .= "\n".'<script type="text/javascript" src="'.$path.'"></script>';
=> $hjs = '<script type="text/javascript" src="'.$path.'"></script>' . $hjs;
Help-File updated
changelog.txt added
------------------------------------------------------------------------------------------------------------------
Version 1.2
First public release

View File

@ -0,0 +1,627 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>jQuery for CMSimple :: Help</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style>
html, body {
margin: 0;
padding: 0;
}
body {
font-family: verdana, arial, sans-serif;
background-color: #e2e2e2;
text-align: center;
font-size: 0.9em;
line-height: 1.3;
}
.additional{
font-size: 90%;
color: #666;
line-height: 1.1;
}
p.code {font-family: Courier New; border: 1px solid #999; background: #eed; padding: 8px 12px;}
</style>
<script type="text/javascript" src="sh/scripts/shCore.js"></script>
<script type="text/javascript" src="sh/scripts/shBrushPhp.js"></script>
<link type="text/css" rel="stylesheet" href="sh/styles/shCore.css">
<link type="text/css" rel="stylesheet" href="sh/styles/shThemeDefault.css">
<script type="text/javascript">
SyntaxHighlighter.config.clipboardSwf = 'sh/scripts/clipboard.swf';
SyntaxHighlighter.all();
</script>
</head>
<body>
<div style="border: 1px solid rgb(187, 187, 187); margin: 0px auto auto; padding: 0pt 3em; text-align: left; width: 780px; background-color: rgb(255, 255, 255);">
<a target="_blank" href="http://jquery.com/"><img style="border: 0px solid ; width: 420px; height: 104px; float: right;" alt="" src="jQuery_logo_color_onwhite.png" vspace="20"></a><a target="_blank" href="http://jqueryui.com/"><img style="border: 0px solid ; width: 448px; height: 108px; float: right;" alt="" src="jQuery__UI_logo_color_onwhite.png" vspace="10"></a>
<h1><a class="mozTocH1" name="mozTocId902206"></a>jQuery
for CMSimple<br>
</h1>
<p>A little CMSimple-System-Plugin which includes jQuery and
jQueryUI to
a CMSimple installation and make the libraries available to use with
other CMSimple-Plugins. </p>
<p class="additional">Version 1.3.1 - 2011-09-30<br>
<span class="additional">
&copy; 2011 Holger Irmler, </span><a class="additional" target="_blank" href="http://cmsimple.holgerirmler.de">http://CMSimple.HolgerIrmler.de</a><span class="additional">.<br>
</span></p>
<br>
<br>
<ol id="mozToc">
<!--mozToc h2 1 h3 2 h4 3--><li><a href="#mozTocId43365">Installation</a></li>
<li><a href="#mozTocId153175">Developers
View</a>
<ol>
<li><a href="#mozTocId683226">How
to use:</a></li>
<li><a href="#mozTocId206541">Using
other jQuery-based plugins / extensions</a></li>
<li><a href="#mozTocId686597">Complete
code-example:
</a></li>
<li><a href="#mozTocId335378">
Where and how to put your own code?</a></li>
<li><a href="#mozTocId191578">Other
things to know...</a></li>
</ol>
</li>
<li><a href="#mozTocId602111">Desingers
View</a></li>
<li><a href="#mozTocId830415">Advanced Usage</a></li>
<li><a href="#mozTocId160751">Licenses</a></li>
<li><a href="#mozTocId753693">Need
help?</a></li>
</ol>
<br>
<h2><a class="mozTocH2" name="mozTocId43365"></a>Installation</h2>
<ol>
<li> <b>Always make a backup of your installation</b>
before adding a new plugin. </li>
<li>Unzip the archive and upload the files and folders into
your
plugins-folder. <span class="additional">
<p>It should look like this: </p>
<ul>
<li>[Root]
<ul>
<li>[2lang]</li>
<li>[cmsimple]</li>
<li>...</li>
<li>[plugins]
<ul>
<li>...</li>
<li>[pluginloader]</li>
<li><b>[jquery]</b>
<ul>
<li><b>[config]</b></li>
<li><span class="additional"><b>[lib]</b></span></li>
<li>admin.php</li>
<li>index.php</li>
<li>jquery.inc.php</li>
</ul>
</li>
<li>index.php</li>
</ul>
</li>
<li>[...]</li>
<li>index.php</li>
</ul>
</li>
</ul>
</span> </li>
<p>The file plugins/jquery/config/config.php needs to be
set
writeable.</p>
<li><span style="font-weight: bold;">You're done! </span><br>
There is no need to activate something&nbsp;somewhere, since the
plugin is normally only used and activated <br>
by other plugins or by itself.&nbsp;So if&nbsp;your intended
use is just running another plugin which need
jQuery for CMSimple, don't bother with reading the rest of this
document.</li>
</ol>
Note: if you're really familiar with jQuery / jQuery UI and you want to
use it without other CMSimple-Plugins too, have a look at the "<a href="#Advanced_Usage">Advanced Usage</a>"
chapter.<br>
<div style="text-align: right;"><a href="#mozToc">Back
to toc</a><br>
</div>
<h2><a class="mozTocH2" name="mozTocId153175"></a>Developers
View</h2>
If you develop a CMSimple plugin, which makes use of jQuery&nbsp;or
jQuery UI, you have to be sure to have the libraries proper loaded
before you run your own script code. A common way in the past was to
include the library core by the plugin function itself. <br>
But that caused a lot of problems with other plugins, like other
library-versions, loaded at the same page.<br>
In some cases all js-code on a page was dropped by&nbsp;js-errors.<br>
<br>
<span style="font-weight: bold;">You're advised <span style="text-decoration: underline;">to use only this plugin</span>
together with all your jQuery based plugins
for CMSimple from now!</span><br>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a><br>
</div>
<h3><a class="mozTocH3" name="mozTocId683226"></a>How
to use:</h3>
The plugin provides a few basic functions, contained in an
include-file. Have a look at the basic code example below:
<ol>
</ol>
<script type="syntaxhighlighter" class="brush: php"><![CDATA[
<?php
function myplugin(){
global $pth, $cf; //be sure CMSimple variables are accessible in your function
$jqerror = '';
if(!file_exists($pth['folder']['plugins'].'jquery/jquery.inc.php')){
$jqerror = '<div class="cmsimplecore_warning">'.
'<b>Ups!</b>'.tag('br').
'Plugin '.ucfirst(basename(dirname(__FILE__))).
' requires jQuery4CMSimple - Plugin!'.tag('br').
'Please download and install jQuery4CMSimple'.tag('br').
'from <a href='.
'"http://cmsimple-xh.com/wiki/doku.php/plugins:jquery4cmsimple">'.
' www.cmsimple-xh.com/wiki</a>.'.
'</div>';
//drop the rest of the plugin-code
return($jqerror);
} else {
//load include-file from jQuery-plugin
//always use "include_once"!
include_once($pth['folder']['plugins'].'jquery/jquery.inc.php');
//include jQuery to the <head>
include_jQuery();
//include jQuery UI to the <head>, if you use it in your plugin
include_jQueryUI();
//....
//your other code ...
//....
}
}
?>
]]></script>
<br>
As you can see, there are just a few necessary steps to include jQuery
&amp; jQuery UI to your own plugin:<br>
<ol>
<li>perform a little error-check and drop your plugin if jQuery
for CMSimple is not available (Line 06 - 16)</li>
<li>include the jquery.inc.php (Line 20)<br>
<span class="additional">You must use "include_<span style="font-weight: bold;">once</span>"
for inclusion, otherwise the script will break with a fatal-error, if
another plugin has included the file already</span></li>
<li>activate jQuery by calling the function include_jQuery() (Line 23)</li>
<li>activate jQuery UI by calling the function include_jQueryUI() (Line 26)</li>
</ol>
Everything else is done and controlled by jQuery for CMSimple.<br>
<br>
You may put your error-message inside a container with
the&nbsp;class-selector "<span style="font-style: italic;">cmsimplecore_warning</span>",
to get the output formatted like other warnings in CMSimple_XH. If
you'll be perfect, add your error-message to your plugins $tx-array and
provide localized texts for the users.<br>
<br>
Beside this, you should mention the dependency of your plugin to jQuery
for CMSimple somewhere in your documentation and on your download-page.
But do not include the jQuery for CMSimple - Plugin to your own
download archive.<br>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a><br>
</div>
<h3><a class="mozTocH3" name="mozTocId206541"></a>Using
other jQuery-based plugins / extensions</h3>
There are a lot of ready to run jQuery-based plugins available on the
web. A good starting-point for an overview can be found at <a href="http://plugins.jquery.com/" target="_blank">http://plugins.jquery.com/</a>.<br>
Using those plugins in your own code may conflict with other
CMSimple-Plugins, loading the same extension.<br>
For this purposes, a third function comes with jQuery for CMSimple:<br>
<script type="syntaxhighlighter" class="brush: php"><![CDATA[
include_jQueryPlugin($name, $path)
]]></script>
where $name is the name of the jQuery-plugin and $path ist the full
path and filename of the js-file to load.<br>
The jQuery for CMSimple - Plugin does not provide single jQuery-plugins
in the download (beside jQuery UI). If you want to use an additional
extension, put it to your own download.<br>
So as an example, let's say your script needs&nbsp;the
jQuery-plugins <span style="font-style: italic;">easing</span>
and&nbsp;<span style="font-style: italic;">mousewheel</span>.<br>
You need to include two additional lines to your plugin-code:<br>
<script type="syntaxhighlighter" class="brush: php"><![CDATA[
<?php
include_jQueryPlugin('easing',
$pth['folder']['plugins'].'myplugin/jquery.easing-1.3.pack.js');
include_jQueryPlugin('mousewheel',
$pth['folder']['plugins'].'myplugin/jquery.mousewheel-3.0.4.pack.js');
?>
]]></script>
Note: to be as much compatible as possible with other CMSimple-plugins,
use only the real-name of the jQuery-plugin for the $name-parameter
when calling the include_jQueryPlugin() - function:<br>
use "<span style="font-style: italic; font-weight: bold;">easing</span>"
<span style="text-decoration: underline;">and not</span><span style="font-weight: bold;"> </span>"<span style="font-style: italic; font-weight: bold;">easing-1.3</span>"
etc. for $name.<br>
jQuery for CMSimple will remember the given name ($name) of every
included plugin. If the extension of your choice is already available,
it will not include it again.<br>
<br>
If you want to have a look at runtime, the names are stored in
the <span style="font-style: italic;">$jQueryPlugins</span>
- Array.<br>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a><br>
</div>
<h3><a class="mozTocH3" name="mozTocId686597"></a>Complete
code-example:<br>
</h3>
<script type="syntaxhighlighter" class="brush: php"><![CDATA[
<?php
function myplugin(){
global $pth, $cf; //be sure CMSimple variables are accessible in your function
$jqerror ='';
if(!file_exists($pth['folder']['plugins'].'jquery/jquery.inc.php')){
$jqerror = '<div class="cmsimplecore_warning">'.
'<b>Ups!</b>'.tag('br').
'Plugin '.ucfirst(basename(dirname(__FILE__))).
' requires jQuery4CMSimple - Plugin!'.tag('br').
'Please download and install jQuery4CMSimple'.tag('br').
'from <a href='.
'"http://cmsimple-xh.com/wiki/doku.php/plugins:jquery4cmsimple">'.
' www.cmsimple-xh.com/wiki</a>.'.
'</div>';
//drop the rest of the plugin-code
return($jqerror);
} else {
//load inculde-file from jQuery-plugin
//always use "include_once"!
include_once($pth['folder']['plugins'].'jquery/jquery.inc.php');
//include jQuery to the <head>
include_jQuery();
//include jQuery UI to the <head>, if you use it in your plugin
include_jQueryUI();
//include other jQuery plugins
include_jQueryPlugin('easing',
$pth['folder']['plugins'].'myplugin/jquery.easing-1.3.pack.js');
include_jQueryPlugin('mousewheel',
$pth['folder']['plugins'].'myplugin/jquery.mousewheel-3.0.4.pack.js');
//....
//your other code ...
//....
}
}
?>
]]></script>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a><br>
</div>
<h3><a class="mozTocH3" name="mozTocId335378"></a>
Where and how to put your own code?</h3>
To include your own code, use the common CMSimple-way:<br>
<br>
If your script goes to the &lt;head&gt; - section, use <span style="font-weight: bold;">$hjs</span>:<br>
<script type="syntaxhighlighter" class="brush: php"><![CDATA[
$hjs .= '<script type="text/javascript">
jQuery(document).ready(function(){...});
&lt;/script>';
]]></script>
If you need to put your code inside the content, do it the same way but
use <span style="font-weight: bold;">$o</span>
variable:<br>
<script type="syntaxhighlighter" class="brush: php"><![CDATA[
$o .= '<script type="text/javascript">
jQuery("p.neat").addClass("ohmy").show("slow");
&lt;/script>';
]]></script>
<br>
<p>
With jQuery4CMSimple, jQuery will always the first loaded JS-Library.<br>
That makes it easy to use other Frameworks, using the $ shorthand, together with jQuery.<br>
To write your code as much compatible as possible
<ul>
<li>don't use '$' - use jQuery() or (function($) { /* your code in here might use $() */ })(jQuery))</li>
<li>don't use jQuerys noConflict() in your plugins</li>
<li>use the " .= " operator to append non-jQuery-libraries on right side of $hjs</li>
<li>include other frameworks <u>in the template</u> always <u>after</u> the line "&lt;?php echo head();?&gt;"</li>
</ul>
For more informations refer to the "Including jQuery before Other Libraries" chapter at the<br>
<a target="_blank" href="http://docs.jquery.com/Using_jQuery_with_Other_Libraries#Including_jQuery_before_Other_Libraries">jQuery-Documentation</a>
or have a look at the discussion at the <a target="_blank" href="http://www.cmsimpleforum.com/viewtopic.php?f=29&t=3209&st=0&sk=t&sd=a&start=20#p18077">Forum</a>.
</p>
<h3><a class="mozTocH3" name="mozTocId191578"></a>Other
things to know...</h3>
The plugin comes with a few more features which are maybe useful for
developers:<br>
<br style="font-weight: bold;">
<span style="font-weight: bold;">To check the
compatibility of your own code</span> <br>
with different jQuery or jQueryUI versions, you can call the include -
functions with the path to the libraries:<br>
<script type="syntaxhighlighter" class="brush: php"><![CDATA[
include_jQuery('http://code.jquery.com/jquery-latest.min.js');
]]></script>
You can use a local or an external path like in the example. Do it for
jQueryUI the same way. But use this feature only in your development
environment. <span style="text-decoration: underline;">Do
not deliver your plugin with a path to a special library-version</span>.
Your releases must always come without a parameter in the function-call.<br>
<br>
<br>
<span style="font-weight: bold;">How to find out which
version of jQuery / jQueryUI is installed:</span><br>
We will keep the plugin up to date and provide from time to time a new
download with&nbsp;new stable versions of the libraries.<br>
Anyway, jQuery for CMSimple defines two constants:<br>
<p class="code">define('JQUERY',
$cf['jquery']['version_core']);</p>
<p class="code">define('JQUERY_UI',
$cf['jquery']['version_ui']);</p>
The constants are holding the version of the libraries in a format like
<span style="font-style: italic;">1.6.1</span> for
example. Note that the values come from the $cf - array which
holds the entries&nbsp;in string-format.<br>
You may include some code to make a version-check on your own, if you
really need that.<br>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a><br>
</div>
<h2><a class="mozTocH2" name="mozTocId602111"></a>Desingers
View</h2>
With jQuery for CMSimple another framework become available: <a href="http://jqueryui.com/home" target="_blank">jQuery
UI</a>.<br>
jQuery UI consists of a number of predefined effects, UI widgets and a
powerful css-based theme framework. <br>
This plugin includes jQuery UI with a default, light grey styled theme
(the smoothness theme). <br>
As a designer you have the chance to provide a complete own
theme&nbsp;, adapted to your template-styles, or a stylesheet-file
with single class-selectors to overwrite settings from the default
theme. <br>
Check the jQuery UI - <a href="http://jqueryui.com/themeroller/" target="_blank">Themeroller</a> to create your own
design from scratch or select a theme from the gallery and customize it.<img style="border: 1px solid ; width: 300px; height: 126px; float: right;" alt="" src="ui_cssfolder.PNG" hspace="5" vspace="5"><br>
<br>
To "activate" your theme-settings, just create a subfolder named
"jquery_ui"
inside your template-folder. <br>
To provide a full ui-theme, put a file namened "<span style="font-weight: bold; font-style: italic;">jquery_ui.css</span>"
inside this folder (but remember: this way, you have to provide a full
ui-theme - maybe with an images-subfolder. The default theme will not
be available!). <br>
<br>
If you only want to overwrite single class-definitions, create a file
named
"<span style="font-weight: bold; font-style: italic;">stylesheet.css</span>"
in the "jquery_ui" - folder. Here, the default theme will be available
and the definitions in your stylesheet.css&nbsp;will overwrite the
contents of the default
theme.&nbsp;<br>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a><br>
</div>
<h2><a class="mozTocH2" name="mozTocId830415"></a><a name="Advanced_Usage"></a>Advanced Usage</h2>
If you're familiar with jQuery / jQuery UI and want to use it with the
WYSIWYG - Editor, you can include jQuery and jQuery UI by default to
your page -&nbsp;&lt;head&gt;, without a installation of
another plugin
or changing your template. Just set the configuration option "<span style="font-weight: bold;">autoload</span>" to "<span style="font-weight: bold;">1</span>" and the libraries
will be available.<br>
<br>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a><br>
</div>
<ol>
</ol>
<h2><a class="mozTocH2" name="mozTocId160751"></a>Licenses</h2>
<ul>
<li><span style="font-weight: bold;">jQuery:</span><br>
Copyright 2011, John Resig<br>
dual licensed under the MIT or GPL Version 2 licenses<br>
see http://jquery.org/license</li>
<li><span style="font-weight: bold;">jQueryUI:</span><br>
Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)<br>
dual licensed under the MIT or GPL Version 2 licenses<br>
see http://jquery.org/license
&amp;&nbsp;http://docs.jquery.com/UI<br>
</li>
<li><span style="font-weight: bold;">jQuery for
CMSimple:</span><br>
Copyright 2011, Holger Irmler<br>
licensed under the GPL Version 2 or later of your choice</li>
</ul>
<div style="text-align: right;"><a href="help.htm#mozToc">Back to toc</a>
</div>
<ol>
</ol>
<h2><a class="mozTocH2" name="mozTocId753693"></a>Need
help?</h2>
<p>... visit <a target="_blank" href="http://www.cmsimpleforum.com">cmsimpleforum.com</a>.</p>
<span style="font-weight: bold;">
<br>
</span>
<pre style="font-weight: bold; line-height: 1.2em; font-size: 90%; color: rgb(102, 102, 102);"> THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED <br> IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND,<br> EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS<br> FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD<br> THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.<br> </pre>
</div>
</body>
</html>

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.2 KiB

View File

@ -0,0 +1,165 @@
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.

Binary file not shown.

View File

@ -0,0 +1,91 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
SyntaxHighlighter.brushes.Php = function()
{
var funcs = 'abs acos acosh addcslashes addslashes ' +
'array_change_key_case array_chunk array_combine array_count_values array_diff '+
'array_diff_assoc array_diff_key array_diff_uassoc array_diff_ukey array_fill '+
'array_filter array_flip array_intersect array_intersect_assoc array_intersect_key '+
'array_intersect_uassoc array_intersect_ukey array_key_exists array_keys array_map '+
'array_merge array_merge_recursive array_multisort array_pad array_pop array_product '+
'array_push array_rand array_reduce array_reverse array_search array_shift '+
'array_slice array_splice array_sum array_udiff array_udiff_assoc '+
'array_udiff_uassoc array_uintersect array_uintersect_assoc '+
'array_uintersect_uassoc array_unique array_unshift array_values array_walk '+
'array_walk_recursive atan atan2 atanh base64_decode base64_encode base_convert '+
'basename bcadd bccomp bcdiv bcmod bcmul bindec bindtextdomain bzclose bzcompress '+
'bzdecompress bzerrno bzerror bzerrstr bzflush bzopen bzread bzwrite ceil chdir '+
'checkdate checkdnsrr chgrp chmod chop chown chr chroot chunk_split class_exists '+
'closedir closelog copy cos cosh count count_chars date decbin dechex decoct '+
'deg2rad delete ebcdic2ascii echo empty end ereg ereg_replace eregi eregi_replace error_log '+
'error_reporting escapeshellarg escapeshellcmd eval exec exit exp explode extension_loaded '+
'feof fflush fgetc fgetcsv fgets fgetss file_exists file_get_contents file_put_contents '+
'fileatime filectime filegroup fileinode filemtime fileowner fileperms filesize filetype '+
'floatval flock floor flush fmod fnmatch fopen fpassthru fprintf fputcsv fputs fread fscanf '+
'fseek fsockopen fstat ftell ftok getallheaders getcwd getdate getenv gethostbyaddr gethostbyname '+
'gethostbynamel getimagesize getlastmod getmxrr getmygid getmyinode getmypid getmyuid getopt '+
'getprotobyname getprotobynumber getrandmax getrusage getservbyname getservbyport gettext '+
'gettimeofday gettype glob gmdate gmmktime ini_alter ini_get ini_get_all ini_restore ini_set '+
'interface_exists intval ip2long is_a is_array is_bool is_callable is_dir is_double '+
'is_executable is_file is_finite is_float is_infinite is_int is_integer is_link is_long '+
'is_nan is_null is_numeric is_object is_readable is_real is_resource is_scalar is_soap_fault '+
'is_string is_subclass_of is_uploaded_file is_writable is_writeable mkdir mktime nl2br '+
'parse_ini_file parse_str parse_url passthru pathinfo readlink realpath rewind rewinddir rmdir '+
'round str_ireplace str_pad str_repeat str_replace str_rot13 str_shuffle str_split '+
'str_word_count strcasecmp strchr strcmp strcoll strcspn strftime strip_tags stripcslashes '+
'stripos stripslashes stristr strlen strnatcasecmp strnatcmp strncasecmp strncmp strpbrk '+
'strpos strptime strrchr strrev strripos strrpos strspn strstr strtok strtolower strtotime '+
'strtoupper strtr strval substr substr_compare';
var keywords = 'and or xor array as break case ' +
'cfunction class const continue declare default die do else ' +
'elseif enddeclare endfor endforeach endif endswitch endwhile ' +
'extends for foreach function include include_once global if ' +
'new old_function return static switch use require require_once ' +
'var while abstract interface public implements extends private protected throw';
var constants = '__FILE__ __LINE__ __METHOD__ __FUNCTION__ __CLASS__';
this.regexList = [
{ regex: SyntaxHighlighter.regexLib.singleLineCComments, css: 'comments' }, // one line comments
{ regex: SyntaxHighlighter.regexLib.multiLineCComments, css: 'comments' }, // multiline comments
{ regex: SyntaxHighlighter.regexLib.doubleQuotedString, css: 'string' }, // double quoted strings
{ regex: SyntaxHighlighter.regexLib.singleQuotedString, css: 'string' }, // single quoted strings
{ regex: /\$\w+/g, css: 'variable' }, // variables
{ regex: new RegExp(this.getKeywords(funcs), 'gmi'), css: 'functions' }, // common functions
{ regex: new RegExp(this.getKeywords(constants), 'gmi'), css: 'constants' }, // constants
{ regex: new RegExp(this.getKeywords(keywords), 'gm'), css: 'keyword' } // keyword
];
this.forHtmlScript(SyntaxHighlighter.regexLib.phpScriptTags);
};
SyntaxHighlighter.brushes.Php.prototype = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Php.aliases = ['php'];

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,30 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('1 y={d:{}};y.d={F:6(S,l,q,k,m,n){6 J(z,Y){1 V=16 15("^"+Y+"\\\\[(?<o>\\\\w+)\\\\]$","14"),x=2;h(1 i=0;i<z.g;i++){7((x=V.17(z[i]))!=2){4 x.o}}4 2};6 3(r,U){4 r!=2?r:U};6 9(s){4 s!=2?s.13():2};1 f=S.18(":"),E=f[0],c={},u={"p":"p"};C={"p":"1a"},v=2,5=d.5;h(1 i 19 f){c[f[i]]="p"}l=9(3(l,5.O));q=9(3(q,5.T));k=9(3(k,5.A));n=9(3(n,5.W));m=9(3(m,5["K-L"]));v={1b:E,O:3(C[c.12],l),T:3(C[c.1g],q),A:3(u[c.A],k),W:3(u[c.1t],n),"K-L":3(J(f,"1q"),m)};4 v},1x:6(B,I,D,H,N,M){6 Z(){1 a=1r;h(1 i=0;i<a.g;i++){7(a[i]===2){10}7(G(a[i])=="1s"&&a[i]!=""){4 a[i]+""}7(G(a[i])=="1c"&&a[i].o!=""){4 a[i].o+""}}4 2};6 t(Q,R,11){1 j=1w.1v(11);h(1 i=0;i<j.g;i++){7(j[i].1u("1p")==R){Q.1n(j[i])}}};1 b=[],1o=2,1f={},1e="1d";t(b,B,"1h");t(b,B,"1i");7(b.g===0){4}h(1 i=0;i<b.g;i++){1 8=b[i],e=Z(8.X["1m"],8.1l,8.X["P"],8.P),1k="";7(e===2){10}e=y.d.F(e,I,D,H,N,M);d.1j(e,8)}}};',62,96,'|var|null|defaultValue|return|defaults|function|if|_26|asString||_21|_11|SyntaxHighlighter|_27|_f|length|for||_1f|_4|_2|_5|_6|value|true|_3|_c|_e|findTagsByName|_12|result||_a|dp|_7|collapse|_14|reverse|_16|_10|parseParams|typeof|_17|_15|getValue|first|line|_19|_18|gutter|language|_1c|_1d|_1|toolbar|_d|_9|ruler|attributes|_8|findValue|continue|_1e|nogutter|toString|gi|XRegExp|new|exec|split|in|false|brush|object|innerHTML|_24|_23|nocontrols|pre|textarea|highlight|_28|className|class|push|_22|name|firstline|arguments|string|showcolumns|getAttribute|getElementsByTagName|document|HighlightAll'.split('|'),0,{}))

Binary file not shown.

After

Width:  |  Height:  |  Size: 786 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 615 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 603 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 309 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 731 B

View File

@ -0,0 +1,330 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
.syntaxhighlighter,
.syntaxhighlighter div,
.syntaxhighlighter code,
.syntaxhighlighter table,
.syntaxhighlighter table td,
.syntaxhighlighter table tr,
.syntaxhighlighter table tbody
{
margin: 0 !important;
padding: 0 !important;
border: 0 !important;
outline: 0 !important;
background: none !important;
text-align: left !important;
float: none !important;
vertical-align: baseline !important;
position: static !important;
left: auto !important;
top: auto !important;
right: auto !important;
bottom: auto !important;
height: auto !important;
width: auto !important;
line-height: 1.1em !important;
font-family: "Consolas", "Bitstream Vera Sans Mono", "Courier New", Courier, monospace !important;
font-weight: normal !important;
font-style: normal !important;
font-size: 1em !important;
min-height: inherit !important; /* For IE8, FF & WebKit */
min-height: auto !important; /* For IE7 */
}
.syntaxhighlighter
{
width: 99% !important; /* 99% fixes IE8 horizontal scrollbar */
margin: 1em 0 1em 0 !important;
padding: 1px !important; /* adds a little border on top and bottom */
position: relative !important;
}
.syntaxhighlighter .bold
{
font-weight: bold !important;
}
.syntaxhighlighter .italic
{
font-style: italic !important;
}
.syntaxhighlighter .line
{
}
.syntaxhighlighter .no-wrap .line .content
{
white-space: pre !important;
}
.syntaxhighlighter .line table
{
border-collapse: collapse !important;
}
.syntaxhighlighter .line td
{
vertical-align: top !important;
}
.syntaxhighlighter .line .number
{
width: 3em !important;
}
.syntaxhighlighter .line .number code
{
width: 2.7em !important;
padding-right: .3em !important;
text-align: right !important;
display: block !important;
}
.syntaxhighlighter .line .content
{
padding-left: .5em !important;
}
.syntaxhighlighter .line .spaces
{
}
/* Disable border and margin on the lines when no gutter option is set */
.syntaxhighlighter.nogutter .line .content
{
border-left: none !important;
}
.syntaxhighlighter .bar
{
display: none !important;
}
.syntaxhighlighter .bar.show
{
display: block !important;
}
.syntaxhighlighter.collapsed .bar
{
display: block !important;
}
/* Adjust some properties when collapsed */
.syntaxhighlighter.collapsed .lines
{
display: none !important;
}
.syntaxhighlighter .lines.no-wrap
{
overflow: auto !important;
overflow-y: hidden !important;
}
/* Styles for the toolbar */
.syntaxhighlighter .toolbar
{
position: absolute !important;
right: 0px !important;
top: 0px !important;
font-size: 1px !important;
padding: 8px 8px 8px 0 !important; /* in px because images don't scale with ems */
}
.syntaxhighlighter.collapsed .toolbar
{
font-size: 80% !important;
padding: .2em 0 .5em .5em !important;
position: static !important;
}
.syntaxhighlighter .toolbar a.item,
.syntaxhighlighter .toolbar .item
{
display: block !important;
float: left !important;
margin-left: 8px !important;
background-repeat: no-repeat !important;
overflow: hidden !important;
text-indent: -5000px !important;
}
.syntaxhighlighter.collapsed .toolbar .item
{
display: none !important;
}
.syntaxhighlighter.collapsed .toolbar .item.expandSource
{
background-image: url(magnifier.png) !important;
display: inline !important;
text-indent: 0 !important;
width: auto !important;
float: none !important;
height: 16px !important;
padding-left: 20px !important;
}
.syntaxhighlighter .toolbar .item.viewSource
{
background-image: url(page_white_code.png) !important;
}
.syntaxhighlighter .toolbar .item.printSource
{
background-image: url(printer.png) !important;
}
.syntaxhighlighter .toolbar .item.copyToClipboard
{
text-indent: 0 !important;
background: none !important;
overflow: visible !important;
}
.syntaxhighlighter .toolbar .item.about
{
background-image: url(help.png) !important;
}
/**
* Print view.
* Colors are based on the default theme without background.
*/
.syntaxhighlighter.printing,
.syntaxhighlighter.printing .line.alt1 .content,
.syntaxhighlighter.printing .line.alt2 .content,
.syntaxhighlighter.printing .line.highlighted .number,
.syntaxhighlighter.printing .line.highlighted.alt1 .content,
.syntaxhighlighter.printing .line.highlighted.alt2 .content,
{
background: none !important;
}
/* Gutter line numbers */
.syntaxhighlighter.printing .line .number
{
color: #bbb !important;
}
/* Add border to the lines */
.syntaxhighlighter.printing .line .content
{
color: #000 !important;
}
/* Toolbar when visible */
.syntaxhighlighter.printing .toolbar
{
display: none !important;
}
.syntaxhighlighter.printing a
{
text-decoration: none !important;
}
.syntaxhighlighter.printing .plain,
.syntaxhighlighter.printing .plain a
{
color: #000 !important;
}
.syntaxhighlighter.printing .comments,
.syntaxhighlighter.printing .comments a
{
color: #008200 !important;
}
.syntaxhighlighter.printing .string,
.syntaxhighlighter.printing .string a
{
color: blue !important;
}
.syntaxhighlighter.printing .keyword
{
color: #069 !important;
font-weight: bold !important;
}
.syntaxhighlighter.printing .preprocessor
{
color: gray !important;
}
.syntaxhighlighter.printing .variable
{
color: #a70 !important;
}
.syntaxhighlighter.printing .value
{
color: #090 !important;
}
.syntaxhighlighter.printing .functions
{
color: #ff1493 !important;
}
.syntaxhighlighter.printing .constants
{
color: #0066CC !important;
}
.syntaxhighlighter.printing .script
{
font-weight: bold !important;
}
.syntaxhighlighter.printing .color1,
.syntaxhighlighter.printing .color1 a
{
color: #808080 !important;
}
.syntaxhighlighter.printing .color2,
.syntaxhighlighter.printing .color2 a
{
color: #ff1493 !important;
}
.syntaxhighlighter.printing .color3,
.syntaxhighlighter.printing .color3 a
{
color: red !important;
}

View File

@ -0,0 +1,173 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
/************************************
* Default Syntax Highlighter theme.
*
* Interface elements.
************************************/
.syntaxhighlighter
{
background-color: #fff !important;
}
/* Highlighed line number */
.syntaxhighlighter .line.highlighted .number
{
color: black !important;
}
/* Highlighed line */
.syntaxhighlighter .line.highlighted.alt1,
.syntaxhighlighter .line.highlighted.alt2
{
background-color: #e0e0e0 !important;
}
/* Gutter line numbers */
.syntaxhighlighter .line .number
{
color: #afafaf !important;
}
/* Add border to the lines */
.syntaxhighlighter .line .content
{
border-left: 3px solid #6CE26C !important;
color: #000 !important;
}
.syntaxhighlighter.printing .line .content
{
border: 0 !important;
}
/* First line */
.syntaxhighlighter .line.alt1
{
background-color: #fff !important;
}
/* Second line */
.syntaxhighlighter .line.alt2
{
background-color: #F8F8F8 !important;
}
.syntaxhighlighter .toolbar
{
background-color: #F8F8F8 !important;
border: #E7E5DC solid 1px !important;
}
.syntaxhighlighter .toolbar a
{
color: #a0a0a0 !important;
}
.syntaxhighlighter .toolbar a:hover
{
color: red !important;
}
/************************************
* Actual syntax highlighter colors.
************************************/
.syntaxhighlighter .plain,
.syntaxhighlighter .plain a
{
color: #000 !important;
}
.syntaxhighlighter .comments,
.syntaxhighlighter .comments a
{
color: #008200 !important;
}
.syntaxhighlighter .string,
.syntaxhighlighter .string a
{
color: blue !important;
}
.syntaxhighlighter .keyword
{
color: #069 !important;
font-weight: bold !important;
}
.syntaxhighlighter .preprocessor
{
color: gray !important;
}
.syntaxhighlighter .variable
{
color: #a70 !important;
}
.syntaxhighlighter .value
{
color: #090 !important;
}
.syntaxhighlighter .functions
{
color: #ff1493 !important;
}
.syntaxhighlighter .constants
{
color: #0066CC !important;
}
.syntaxhighlighter .script
{
background-color: yellow !important;
}
.syntaxhighlighter .color1,
.syntaxhighlighter .color1 a
{
color: #808080 !important;
}
.syntaxhighlighter .color2,
.syntaxhighlighter .color2 a
{
color: #ff1493 !important;
}
.syntaxhighlighter .color3,
.syntaxhighlighter .color3 a
{
color: red !important;
}

View File

@ -0,0 +1,176 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
/**
* Django SyntaxHighlighter theme
*/
/************************************
* Interface elements.
************************************/
.syntaxhighlighter
{
background-color: #0B2F20 !important;
}
/* Gutter line numbers */
.syntaxhighlighter .line .number
{
color: #497958 !important;
}
/* Add border to the lines */
.syntaxhighlighter .line .content
{
border-left: 3px solid #41A83E !important;
color: #B9BDB6 !important;
}
.syntaxhighlighter.printing .line .content
{
border: 0 !important;
}
/* First line */
.syntaxhighlighter .line.alt1
{
}
/* Second line */
.syntaxhighlighter .line.alt2
{
background-color: #0a2b1d !important;
}
/* Highlighed line number */
.syntaxhighlighter .line.highlighted .number
{
background-color: #336442 !important;
color: #fff !important;
}
/* Highlighed line */
.syntaxhighlighter .line.highlighted.alt1,
.syntaxhighlighter .line.highlighted.alt2
{
background-color: #336442 !important;
}
.syntaxhighlighter .toolbar
{
background-color: #245032 !important;
border: #0B2F20 solid 1px !important;
}
.syntaxhighlighter .toolbar a
{
color: #C4B14A !important;
}
.syntaxhighlighter .toolbar a:hover
{
color: #FFE862 !important;
}
/************************************
* Actual syntax highlighter colors.
************************************/
.syntaxhighlighter .plain,
.syntaxhighlighter .plain a
{
color: #F8F8F8 !important;
}
.syntaxhighlighter .comments,
.syntaxhighlighter .comments a
{
color: #336442 !important;
font-style: italic !important;
}
.syntaxhighlighter .string,
.syntaxhighlighter .string a
{
color: #9DF39F !important;
}
.syntaxhighlighter .keyword
{
color: #96DD3B !important;
font-weight: bold !important;
}
.syntaxhighlighter .preprocessor
{
color: #91BB9E !important;
}
.syntaxhighlighter .variable
{
color: #FFAA3E !important;
}
.syntaxhighlighter .value
{
color: #F7E741 !important;
}
.syntaxhighlighter .functions
{
color: #FFAA3E !important;
}
.syntaxhighlighter .constants
{
color: #E0E8FF !important;
}
.syntaxhighlighter .script
{
background-color: #497958 !important;
}
.syntaxhighlighter .color1,
.syntaxhighlighter .color1 a
{
color: #EB939A !important;
}
.syntaxhighlighter .color2,
.syntaxhighlighter .color2 a
{
color: #91BB9E !important;
}
.syntaxhighlighter .color3,
.syntaxhighlighter .color3 a
{
color: #EDEF7D !important;
}

View File

@ -0,0 +1,190 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
/**
* Eclipse IDE SyntaxHighlighter color theme
* (C) Code-House
* http://blog.code-house.org/2009/10/xml-i-adnotacje-kod-ogolnego-przeznaczenia-i-jpa/
*/
.syntaxhighlighter
{
background-color: #fff !important;
}
/* Highlighed line number */
.syntaxhighlighter .line.highlighted .number
{
background-color: #c3defe !important;
}
/* Highlighed line */
.syntaxhighlighter .line.highlighted.alt1,
.syntaxhighlighter .line.highlighted.alt2
{
background-color: #c3defe !important;
}
/* Gutter line numbers */
.syntaxhighlighter .line .number
{
color: #787878 !important;
background-color: #fff !important;
}
/* Add border to the lines */
.syntaxhighlighter .line .content
{
border-left: 1px solid #d4d0c8 !important;
color: #000 !important;
}
.syntaxhighlighter.printing .line .content
{
border: 0 !important;
}
/* First line */
.syntaxhighlighter .line.alt1
{
background-color: #fff !important;
}
/* Second line */
.syntaxhighlighter .line.alt2
{
background-color: #fff !important;
}
.syntaxhighlighter .toolbar
{
background-color: #F8F8F8 !important;
border: #E7E5DC solid 1px !important;
}
.syntaxhighlighter .toolbar a
{
color: #a0a0a0 !important;
}
.syntaxhighlighter .toolbar a:hover
{
color: red !important;
}
/************************************
* Actual syntax highlighter colors.
************************************/
.syntaxhighlighter .plain,
.syntaxhighlighter .plain a
{
color: #000 !important;
}
.syntaxhighlighter .comments,
.syntaxhighlighter .comments a
{
color: #3f5fbf !important;
}
.syntaxhighlighter .string,
.syntaxhighlighter .string a
{
color: #2a00ff !important;
}
.syntaxhighlighter .keyword
{
color: #7f0055 !important;
font-weight: bold !important;
}
.syntaxhighlighter .preprocessor
{
color: #646464 !important;
}
.syntaxhighlighter .variable
{
color: #a70 !important;
}
.syntaxhighlighter .value
{
color: #090 !important;
}
.syntaxhighlighter .functions
{
color: #ff1493 !important;
}
.syntaxhighlighter .constants
{
color: #0066CC !important;
}
.syntaxhighlighter .script
{
background-color: yellow !important;
}
.syntaxhighlighter .color1,
.syntaxhighlighter .color1 a
{
color: #808080 !important;
}
.syntaxhighlighter .color2,
.syntaxhighlighter .color2 a
{
color: #ff1493 !important;
}
.syntaxhighlighter .color3,
.syntaxhighlighter .color3 a
{
color: red !important;
}
.xml .keyword {
color: #3f7f7f !important;
font-weight: normal !important;
}
.xml .color1,
.xml .color1 a{
color: #7f007f !important;
}
.xml .string {
font-style: italic !important;
color: #2a00ff !important;
}

View File

@ -0,0 +1,175 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
/**
* Emacs SyntaxHighlighter theme based on theme by Joshua Emmons
* http://www.skia.net/
*/
/************************************
* Interface elements.
************************************/
.syntaxhighlighter
{
background-color: #000000 !important;
}
/* Gutter line numbers */
.syntaxhighlighter .line .number
{
color: #D3D3D3 !important;
}
/* Add border to the lines */
.syntaxhighlighter .line .content
{
border-left: 3px solid #990000 !important;
color: #B9BDB6 !important;
}
.syntaxhighlighter.printing .line .content
{
border: 0 !important;
}
/* First line */
.syntaxhighlighter .line.alt1
{
}
/* Second line */
.syntaxhighlighter .line.alt2
{
background-color: #0f0f0f !important;
}
/* Highlighed line number */
.syntaxhighlighter .line.highlighted .number
{
background-color: #435A5F !important;
color: #fff !important;
}
/* Highlighed line */
.syntaxhighlighter .line.highlighted.alt1,
.syntaxhighlighter .line.highlighted.alt2
{
background-color: #435A5F !important;
}
.syntaxhighlighter .toolbar
{
background-color: #000000 !important;
border: #000000 solid 1px !important;
}
.syntaxhighlighter .toolbar a
{
color: #646763 !important;
}
.syntaxhighlighter .toolbar a:hover
{
color: #9CCFF4 !important;
}
/************************************
* Actual syntax highlighter colors.
************************************/
.syntaxhighlighter .plain,
.syntaxhighlighter .plain a
{
color: #D3D3D3 !important;
}
.syntaxhighlighter .comments,
.syntaxhighlighter .comments a
{
color: #FF7D27 !important;
}
.syntaxhighlighter .string,
.syntaxhighlighter .string a
{
color: #FF9E7B !important;
}
.syntaxhighlighter .keyword
{
color: #00FFFF !important;
}
.syntaxhighlighter .preprocessor
{
color: #AEC4DE !important;
}
.syntaxhighlighter .variable
{
color: #FFAA3E !important;
}
.syntaxhighlighter .value
{
color: #090 !important;
}
.syntaxhighlighter .functions
{
color: #81CEF9 !important;
}
.syntaxhighlighter .constants
{
color: #FF9E7B !important;
}
.syntaxhighlighter .script
{
background-color: #990000 !important;
}
.syntaxhighlighter .color1,
.syntaxhighlighter .color1 a
{
color: #EBDB8D !important;
}
.syntaxhighlighter .color2,
.syntaxhighlighter .color2 a
{
color: #FF7D27 !important;
}
.syntaxhighlighter .color3,
.syntaxhighlighter .color3 a
{
color: #AEC4DE !important;
}

View File

@ -0,0 +1,177 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
/**
* Fade to Grey SyntaxHighlighter theme based on theme by Brasten Sager
* http://www.ibrasten.com/
*/
/************************************
* Interface elements.
************************************/
.syntaxhighlighter
{
background-color: #121212 !important;
}
/* Gutter line numbers */
.syntaxhighlighter .line .number
{
color: #C3C3C3 !important;
}
/* Add border to the lines */
.syntaxhighlighter .line .content
{
border-left: 3px solid #3185B9 !important;
color: #B9BDB6 !important;
}
.syntaxhighlighter.printing .line .content
{
border: 0 !important;
}
/* First line */
.syntaxhighlighter .line.alt1
{
}
/* Second line */
.syntaxhighlighter .line.alt2
{
background-color: #000000 !important;
}
/* Highlighed line number */
.syntaxhighlighter .line.highlighted .number
{
background-color: #3A3A00 !important;
color: #fff !important;
}
/* Highlighed line */
.syntaxhighlighter .line.highlighted.alt1,
.syntaxhighlighter .line.highlighted.alt2
{
background-color: #3A3A00 !important;
}
.syntaxhighlighter .toolbar
{
background-color: #000000 !important;
border: #000000 solid 1px !important;
}
.syntaxhighlighter .toolbar a
{
color: #808080 !important;
}
.syntaxhighlighter .toolbar a:hover
{
color: #96DAFF !important;
}
/************************************
* Actual syntax highlighter colors.
************************************/
.syntaxhighlighter .plain,
.syntaxhighlighter .plain a
{
color: #FFFFFF !important;
}
.syntaxhighlighter .comments,
.syntaxhighlighter .comments a
{
color: #696854 !important;
}
.syntaxhighlighter .string,
.syntaxhighlighter .string a
{
color: #E3E658 !important;
}
.syntaxhighlighter .keyword
{
color: #D01D33 !important;
}
.syntaxhighlighter .preprocessor
{
color: #435A5F !important;
}
.syntaxhighlighter .variable
{
color: #898989 !important;
}
.syntaxhighlighter .value
{
color: #090 !important;
}
.syntaxhighlighter .functions
{
color: #AAAAAA !important;
font-weight: bold !important;
}
.syntaxhighlighter .constants
{
color: #96DAFF !important;
}
.syntaxhighlighter .script
{
background-color: #C3C3C3 !important;
color: #000 !important;
}
.syntaxhighlighter .color1,
.syntaxhighlighter .color1 a
{
color: #FFC074 !important;
}
.syntaxhighlighter .color2,
.syntaxhighlighter .color2 a
{
color: #4A8CDB !important;
}
.syntaxhighlighter .color3,
.syntaxhighlighter .color3 a
{
color: #96DAFF !important;
}

View File

@ -0,0 +1,175 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
/**
* Midnight SyntaxHighlighter theme based on theme by J.D. Myers
* http://webdesign.lsnjd.com/
*/
/************************************
* Interface elements.
************************************/
.syntaxhighlighter
{
background-color: #0F192A !important;
}
/* Gutter line numbers */
.syntaxhighlighter .line .number
{
color: #38566F !important;
}
/* Add border to the lines */
.syntaxhighlighter .line .content
{
border-left: 3px solid #435A5F !important;
color: #B9BDB6 !important;
}
.syntaxhighlighter.printing .line .content
{
border: 0 !important;
}
/* First line */
.syntaxhighlighter .line.alt1
{
background-color: #0F192A !important;
}
/* Second line */
.syntaxhighlighter .line.alt2
{
background-color: #0F192A !important;
}
/* Highlighed line number */
.syntaxhighlighter .line.highlighted .number
{
background-color: #253E5A !important;
color: #fff !important;
}
/* Highlighed line */
.syntaxhighlighter .line.highlighted.alt1,
.syntaxhighlighter .line.highlighted.alt2
{
background-color: #253E5A !important;
}
.syntaxhighlighter .toolbar
{
background-color: #0F192A !important;
}
.syntaxhighlighter .toolbar a
{
color: #38566F !important;
}
.syntaxhighlighter .toolbar a:hover
{
color: #8AA6C1 !important;
}
/************************************
* Actual syntax highlighter colors.
************************************/
.syntaxhighlighter .plain,
.syntaxhighlighter .plain a
{
color: #D1EDFF !important;
}
.syntaxhighlighter .comments,
.syntaxhighlighter .comments a
{
color: #428BDD !important;
}
.syntaxhighlighter .string,
.syntaxhighlighter .string a
{
color: #1DC116 !important;
}
.syntaxhighlighter .keyword
{
color: #B43D3D !important;
}
.syntaxhighlighter .preprocessor
{
color: #8AA6C1 !important;
}
.syntaxhighlighter .variable
{
color: #FFAA3E !important;
}
.syntaxhighlighter .value
{
color: #F7E741 !important;
}
.syntaxhighlighter .functions
{
color: #FFAA3E !important;
}
.syntaxhighlighter .constants
{
color: #E0E8FF !important;
}
.syntaxhighlighter .script
{
background-color: #404040 !important;
}
.syntaxhighlighter .color1,
.syntaxhighlighter .color1 a
{
color: #F8BB00 !important;
}
.syntaxhighlighter .color2,
.syntaxhighlighter .color2 a
{
color: #FFFFFF !important;
}
.syntaxhighlighter .color3,
.syntaxhighlighter .color3 a
{
color: #FFAA3E !important;
}

View File

@ -0,0 +1,175 @@
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.1.382 (June 24 2010)
*
* @copyright
* Copyright (C) 2004-2009 Alex Gorbatchev.
*
* @license
* This file is part of SyntaxHighlighter.
*
* SyntaxHighlighter is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* SyntaxHighlighter is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SyntaxHighlighter. If not, see <http://www.gnu.org/copyleft/lesser.html>.
*/
/**
* RDark SyntaxHighlighter theme based on theme by Radu Dineiu
* http://www.vim.org/scripts/script.php?script_id=1732
*/
/************************************
* Interface elements.
************************************/
.syntaxhighlighter
{
background-color: #1B2426 !important;
}
/* Gutter line numbers */
.syntaxhighlighter .line .number
{
color: #B9BDB6 !important;
}
/* Add border to the lines */
.syntaxhighlighter .line .content
{
border-left: 3px solid #435A5F !important;
color: #B9BDB6 !important;
}
.syntaxhighlighter.printing .line .content
{
border: 0 !important;
}
/* First line */
.syntaxhighlighter .line.alt1
{
background-color: #1B2426 !important;
}
/* Second line */
.syntaxhighlighter .line.alt2
{
background-color: #1B2426 !important;
}
/* Highlighed line number */
.syntaxhighlighter .line.highlighted .number
{
background-color: #435A5F !important;
color: #fff !important;
}
/* Highlighed line */
.syntaxhighlighter .line.highlighted.alt1,
.syntaxhighlighter .line.highlighted.alt2
{
background-color: #435A5F !important;
}
.syntaxhighlighter .toolbar
{
background-color: #1B2426 !important;
}
.syntaxhighlighter .toolbar a
{
color: #646763 !important;
}
.syntaxhighlighter .toolbar a:hover
{
color: #E0E8FF !important;
}
/************************************
* Actual syntax highlighter colors.
************************************/
.syntaxhighlighter .plain,
.syntaxhighlighter .plain a
{
color: #B9BDB6 !important;
}
.syntaxhighlighter .comments,
.syntaxhighlighter .comments a
{
color: #878A85 !important;
}
.syntaxhighlighter .string,
.syntaxhighlighter .string a
{
color: #5CE638 !important;
}
.syntaxhighlighter .keyword
{
color: #5BA1CF !important;
}
.syntaxhighlighter .preprocessor
{
color: #435A5F !important;
}
.syntaxhighlighter .variable
{
color: #FFAA3E !important;
}
.syntaxhighlighter .value
{
color: #090 !important;
}
.syntaxhighlighter .functions
{
color: #FFAA3E !important;
}
.syntaxhighlighter .constants
{
color: #E0E8FF !important;
}
.syntaxhighlighter .script
{
background-color: #435A5F !important;
}
.syntaxhighlighter .color1,
.syntaxhighlighter .color1 a
{
color: #E0E8FF !important;
}
.syntaxhighlighter .color2,
.syntaxhighlighter .color2 a
{
color: #FFFFFF !important;
}
.syntaxhighlighter .color3,
.syntaxhighlighter .color3 a
{
color: #FFAA3E !important;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

View File

@ -0,0 +1,29 @@
<?php // utf8-marker: äöü
if (!defined('CMSIMPLE_VERSION') || preg_match('#/jquery/index.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
/*
=========================================================
Adapted for CMSimple 4.0 and higher:
Gert Ebersbach 2013
ge-webdesign.de
=========================================================
based on "jQuery for CMSimple" version 1.3 2011-07-27
author: Holger Irmler - cmsimple.holgerirmler.de
*/
if (!defined('CMSIMPLE_VERSION') || strstr($_SERVER['SCRIPT_NAME'],'/jquery/index.php'))
{
die('no direct access');
}
if($cf['jquery']['autoload'] == "1")
{
include_once($pth['folder']['plugins'].'jquery/jquery.inc.php');
include_jQuery();
include_jQueryUI();
}
?>

View File

@ -0,0 +1,128 @@
<?php // utf8-marker: äöü
if (!defined('CMSIMPLE_VERSION') || preg_match('#jquery/jquery.inc.php#i',$_SERVER['SCRIPT_NAME']))
{
die('no direct access');
}
/*
=========================================================
Adapted for CMSimple 4.0 and higher:
Gert Ebersbach 2013
ge-webdesign.de
Last Change: 2019-01 for CMSimple 4.7.8
=========================================================
based on "jQuery for CMSimple" version 1.3 2011-07-27
author: Holger Irmler - cmsimple.holgerirmler.de
*/
function include_jQuery($path='')
{
global $pth, $cf, $hjs, $adm;
if(!defined('JQUERY'))
{
if($path == '')
{
if(isset($_REQUEST['pagemanager']) && $adm)
{
$path = $pth['folder']['plugins'] . 'jquery/lib/jquery/jquery_cmsimplecore.js';
}
else
{
$path = $pth['folder']['plugins'] . 'jquery/lib/jquery/' . $cf['jquery']['file_core'];
}
if(!file_exists($path))
{
e('missing', 'file', $path);
return;
}
}
if(!strstr($hjs,$cf['jquery']['file_core']) && !strstr($hjs,'jquery_cmsimplecore.js'))
{
$hjs = '<script src="' . $path . '"></script>' . "\n" . $hjs;
}
}
}
function include_jQueryUI($path='')
{
global $pth, $cf, $hjs, $adm;
if($path == '')
{
if(isset($_REQUEST['pagemanager']) && $adm)
{
$path = $pth['folder']['plugins'] . 'jquery/lib/jquery_ui/jquery-ui_cmsimplecore.js';
}
else
{
$path = $pth['folder']['plugins'] . 'jquery/lib/jquery_ui/' . $cf['jquery']['file_ui'];
}
if(!file_exists($path))
{
e('missing', 'file', $path);
return;
}
}
if(!strstr($hjs,$cf['jquery']['file_ui']) && !strstr($hjs,'jquery-ui_cmsimplecore.js'))
{
$hjs.= '<script src="' . $path . '"></script>' . "\n";
}
if(file_exists($pth['folder']['template'].'jquery_ui/jquery_ui.css'))
{
//load a complete custom ui-theme
$hjs .= "\n".tag('link rel="stylesheet" type="text/css" media="screen" href="' . $pth['folder']['template'] . 'jquery_ui/jquery_ui.css"');
}
else
{
//load the default theme
if(!strstr($hjs,$cf['jquery']['file_css']) && !isset($_REQUEST['pagemanager']))
{
$hjs = tag('link rel="stylesheet" type="text/css" media="screen" href="' . $pth['folder']['plugins'] . 'jquery/lib/jquery_ui/css/' . $cf['jquery']['file_css'] . '"') . "\n" . $hjs;
}
//include a custom css-file to overwrite single selectors
if(file_exists($pth['folder']['template'].'jquery_ui/stylesheet.css'))
{
$hjs.= "\n" . tag('link rel="stylesheet" type="text/css" media="screen" href="' . $pth['folder']['template'] . 'jquery_ui/stylesheet.css"');
}
//include pagemanager jquery css file
if(!strstr($hjs,'jqueryui_cmsimplecore.css') && isset($_REQUEST['pagemanager']) && $adm)
{
$hjs.= "\n" . '<link rel="stylesheet" type="text/css" media="screen" href="' . $pth['folder']['plugins'] . 'jquery/lib/jquery_ui/css/cmsimplecore/jqueryui_cmsimplecore.css">' . "\n";
}
}
}
function include_jQueryPlugin($name='', $path='')
{
global $hjs, $jQueryPlugins;
if(!isset($jQueryPlugins))
{
$jQueryPlugins = array();
}
if($name != '')
{
if(!file_exists($path))
{
e('missing', 'file', $path);
return;
}
$name = strtolower($name);
if (!in_array($name, $jQueryPlugins))
{
$hjs.= '<script src="' . $path . '"></script>' . "\n";
$jQueryPlugins[] .= $name;
}
}
}
?>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 212 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 208 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 335 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 207 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 262 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 262 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 332 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 280 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 180 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 178 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 120 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 105 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 111 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 110 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 119 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 101 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

Some files were not shown because too many files have changed in this diff Show More