isp - new mediainsert cases

This commit is contained in:
Ian 2014-09-07 10:12:34 +02:00
parent 927b6ef246
commit f14cec04a2
10 changed files with 357 additions and 537 deletions

View file

@ -1,4 +1,14 @@
0.42:
-----
* Merge new xml structure "picperrow" and "hideafter" by user "nogat"
http://board.s9y.org/viewtopic.php?f=4&t=20058, 2014-08-22
* add some media gallery css
* minors for version switch
0.41:
-----
* removed wrong slash in plugin_mediainsert.tpl fullimage link path

View file

@ -1,185 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Dokumentace: Avatar Plugin</title>
</head>
<body>
<h1>Dokumentace pluginy Serendipity ImageSelectorPlus</h1>
<p>Dokumentaci k tomuto pluginu přeložil do češtiny Vladimír Ajgl (vlada [zavinac] ajgl [tecka] cz) dne 26.6.2011. Od té doby mohl být plugin pozměněn nebo mohly být rozšířené jeho funkce. Zkontrolujte pro jistotu i <a href="../documentation_en.html">anglickou dokumentaci</a> a <a href="../ChangeLog">ChangeLog</a>.
<h2>Obecný popis</h2>
<p>
Plugin ImageSelectorPlus se používá k usnadnění práce s obrázky, především k vkládání obrázků z mediatéky (interní galerie Serendipity).
</p>
<h2>QuickBlog</h2>
<p>
Při nahrávání obrázku ho rovnou můžete vystavit jako příspěvek. Řiďte se podle instrukcí nad formulářem QuickBlogu na straně s nahráváním souborů.
</p>
<h3>Změna vzhledu příspěvku QuickBlogu</h3>
<p>
Plugin používá šablonu "plugin_quickblog.tpl". Její změnou změníte vzhled vkládaných obrázků.
</p>
<p>Informace o obrázku jsou uchovány v poli {$quickblog}, které má tyto části:
<ul>
<li>fullimage - cesta a název velkého souboru</li>
<li>image - cesta a název k náhledu</li>
<li>body - tělo příspěvku</li>
<li>exif_mode - způsob získání exif tagů z fotky ('internal', 'jhead', 'none')</li>
<li>exif - pole obsahující různé exif tagy, pro jejich názvy si najděte dokumentaci exif tagů - jejich názvy použijte následovně, příklad $quickblog.exif.COMMENT nebo $quickblog.exif.Focal_length</li>
</ul>
</p>
<h2>Hromadné vkládání obrázků</h2>
Další funkcí je hromadné vkládání obrázků. Funguje na principu, že v textu příspěvku napíšete xml strukturu, kterou plugin nahradí obrázky z databáze.
</p>
<h3>Kdy se to hodí?</h3>
<p>
Když píšete fotoblog a potřebujete do příspěvku vkládat více obrázků najednou. Když máte padesát fotek, které jsou navíc očíslované, tak je můžete vložit buď po jedné, jak to Serendipity umožňují v základu, nebo pomocí jediné řádky s použitím popisovaného pluginu.
</p>
<h3>Příklady</h3>
<h4>Příklad 1 - vkládáme části galerie</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="single" name="pict0034" /&gt;
&lt;media type="single" name="pict0032" /&gt;
&lt;media type="range" prefix="pict00" start="35" stop="52" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
Takto vložíme z galerie "MyHolidays" obrázek "pict0034", po něm obrázek "pict0032" a pak všechny obrázky od "pict0035" do "pict0052".
<ul>
Chování pluginu:
<li>Zobrazuje pouze obrázky, které jsou přítomny v databázi. Takže pokud zrovna obrázky 44,45,48 a 50 v databázi nejsou, pluginu to nevadí a nespadne. Jednoduše tyto obrázky vynechá.</li>
<li>Zachovává pořadí obrázků z xml. Tedy obrázek 34 bude zobrazen před obrázkem 32.</li>
</ul>
</p>
<h4>Příklad 2 - vkládáme celou galerii najednou</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<h3>Důležité</h3>
<p>Plugin je relativně citlivý na (ne)správnost syntaxe xml. Pokud není bezchybná, typicky zapomenete na ukončovací zpětné lomítko v tagu media, můžete vyřadit z činnosti celý blog!!! (prostě není ošetřená kontrola správnosti syntaxe a parser na špatné syntaxi havaruje)</p>
<h3>Přehled xml tagů</h3>
<dl>
<dt>&lt;mediainsert&gt;</dt>
<dd>hlavní kontejner pro vkládané obrázky</dd>
<dt>&lt;gallery&gt;</dt>
<dd>cesta ke galerii, ze které mají být brány obrázky (reltivně k adresáři uploads/ - bez úvodního lomítka a s ukončujícím lomítkem - "MyHolidays" nebo "/MyHolidays/" jsou špatně. Správně je "MyHolidays/".)</dd>
<dt>&lt;media&gt;</dt>
<dd>Určuje, které obrázky mají být vloženy. Na základě atributu "type" je možno vložit obrázky třemi způsoby:
<ul>
<li>"single" - vloží jeden obrázek se jménem zadaným atributem "name"</li>
<li>"gallery" - bez dalších atributů, vloží celou galerii</li>
<li>"range" - vloží číslované obrázky od obrázku "prefix""start" do obrázku "prefix""stop" (viz. příklad 1)</li>
</ul>
</dd>
</dl>
<h3>Změna vzhledu vkládaných obrázků</h3>
<p>
Plugin používá šablonu "plugin_mediainsert.tpl". Její změnou změníte vzhled vkládaných obrázků.</p>
<p>Informace o obrázku jsou uchovány v poli {$plugin_mediainsert_media}, které má tyto části:
<ul>
<li>name - jméno obrázku (název souboru bez přípony)</li>
<li>extension - přípona souboru</li>
<li>realname - celé jméno souboru, to samé jako {$name}.{$extension}</li>
<li>thumbnail_name - název souboru s náhledem dostanete následovně - {$name}.{$thumbnail_name}.{$extension}</li>
<li>path - cesta ke galerii, stejná hodnota, kteoru zadáváte v tagu "gallery"</li>
<li>comment1 - krátký komentář z databáze</li>
<li>width - šířka původního (velkého) obrázku</li>
<li>height - výška původního (velkého) obrázku</li>
<li>thumbwidth - šířka náhledu</li>
<li>thumbheight - výška náhledu</li>
</ul>
</p>
<h2>Rozbalování ZIP archivů</h2>
<h3>K čemu je to dobré</h3>
<p>Kupříkladu když chcete nahrát mnoho souborů najednou. Nemusíte vybírat jednotlivé soubory po jednom (což je zdlouhavé). Prostě je zabalíte do zip archivu, nahrajete tento archiv a ten bude na blogu rozbalen.</p>
<h3>Vlastnosti rozbalování ZIPů</h3>
<p>
<ul>
<li>Soubory z archivu jsou rozbaleny do stejného adresáře, do kterého je nahrán archiv.</li>
<li>Rozbalené soubor (což nemusí být nutně obrázky) jsou vloženy do databáze médií.</li>
<li>Pokud zvolíte volbu "Zadat vlastnosti", rozbalené obrázky se také zorazí pro zadávání vlastností.</li>
<li>Nenahrávejte ZIP archivy s podadersáři. Netestoval jsem to, ale obávám se, že se tyto adresáře nevytvoří a všechny soubory se rozbalí do jednoho adresáře.</li>
<li>Dávejte pozor na velikost ZIP archivu. Na webu máte nastavené určité omezení týkající se maximální velikosti nahrávaného souboru (obvykle to bývá 10MB).</li>
</ul>
</p>
<h2>Automatická změna velikosti obrázků</h2>
<p>Tato funkce automaticky prohledá příspěvek blogu a vyhledá obrázky, které jsou zadány ve formě:</p>
<pre>
&lt;img src="/uploads/mujobrazek.jpg" width="100" height="150" /&gt;
</pre>
<p>Když najde obrázek v tomto formátu (pokud najde obrázek s definovanou výškou a/nebo šířkou), nahradí jeho atribut 'src' (adresa obrázku) odkazem na skript pro změnu velikosti obrázku 'serendipity_admin_image_selector.php'. Tedy přepíše odkaz na něco jako:</p>
<pre>
&lt;img src="http://www.mujblog.cz/serendipity_admin_image_selector.php?serendipity[image]=1&serendipity[disposition]=inline&serendipity[step]=showItem&serendipity[resizeWidth]=100&serendipity[resizeHeight]=150" width="100" height="150" /&gt;
</pre>
<p>Tato vlastnost šetří váš čás, pokud potřebujete použít stejný obrázek ve více rozlišeních a může také ušetřit čas nutný pro stažení obrázků při prohlížení vašeho blogu. Vliv na rychlost blogu je minimální, protože se změna velikosti obrázku provede jenom jednou, při prvním přepisu tagu &lt;img&gt;.
</p>
<h3>Poznámky</h3>
<ol>
<li>Poměr stran obrázku je zachován.</li>
<li>Stačí definovat pouze jeden z atributů 'width' nebo 'height'. Pokud není zadán žádný z nich, obrázek je ignorován a adresa není nahrazena adresou na skript pro změnu velikosti obrázku.</li>
<li>Pokud jsou zadány dohromady jak šířka ('width'), tak výška ('height'), obrázek bude zvětšen/zmenšen při zachování poměrů stran tak, aby se vešel do zadané oblasti.</li>
</ol>
<h2>Autoři</h2>
<p>
Garvin Hicking, Německo - všechno ostatní<br />
Vladimír Ajgl (vlada [at] ajgl [dot] cz), Česká republika, 19.11.2007 - hromadné vkládání obrázků do příspěvků pomocí XML, hromadné nahrávání v ZIP souboru
</p>
<h2>Historie verzí (ChangeLog)</h2>
<ul>
<li>nejnovější verze</li>
<ul>
<li>Dopředná kompatibilita se smarty3</li>
</ul>
<li>verze 0.28</li>
<ul>
<li>Předávání proměnné $eventData do šablony plugin_mediainsert.tpl, pomocí smarty tagu {$plugin_mediainsert_entry}.</li>
</ul>
<li>verze 0.20 [Vladimír Ajgl]</li>
<ul>
<li>Přidána dokumentace (documentation_en.html, documentation_cs.html)</li>
<li>Přidán český překlad</li>
<li>Přidána funkce hromadného vkládání fotek do příspěvků pomocí XML kódu (pouze s PHP5)</li>
</ul>
</ul>
</body>
</html>

View file

@ -1,185 +0,0 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Dokumentace: Avatar Plugin</title>
</head>
<body>
<h1>Dokumentace pluginy Serendipity ImageSelectorPlus</h1>
<p>Dokumentaci k tomuto pluginu přeložil do češtiny Vladimír Ajgl (vlada [zavinac] ajgl [tecka] cz) dne 26.6.2011. Od té doby mohl být plugin pozměněn nebo mohly být rozšířené jeho funkce. Zkontrolujte pro jistotu i <a href="../documentation_en.html">anglickou dokumentaci</a> a <a href="../ChangeLog">ChangeLog</a>.
<h2>Obecný popis</h2>
<p>
Plugin ImageSelectorPlus se používá k usnadnění práce s obrázky, především k vkládání obrázků z mediatéky (interní galerie Serendipity).
</p>
<h2>QuickBlog</h2>
<p>
Při nahrávání obrázku ho rovnou můžete vystavit jako příspěvek. Řiďte se podle instrukcí nad formulářem QuickBlogu na straně s nahráváním souborů.
</p>
<h3>Změna vzhledu příspěvku QuickBlogu</h3>
<p>
Plugin používá šablonu "plugin_quickblog.tpl". Její změnou změníte vzhled vkládaných obrázků.
</p>
<p>Informace o obrázku jsou uchovány v poli {$quickblog}, které má tyto části:
<ul>
<li>fullimage - cesta a název velkého souboru</li>
<li>image - cesta a název k náhledu</li>
<li>body - tělo příspěvku</li>
<li>exif_mode - způsob získání exif tagů z fotky ('internal', 'jhead', 'none')</li>
<li>exif - pole obsahující různé exif tagy, pro jejich názvy si najděte dokumentaci exif tagů - jejich názvy použijte následovně, příklad $quickblog.exif.COMMENT nebo $quickblog.exif.Focal_length</li>
</ul>
</p>
<h2>Hromadné vkládání obrázků</h2>
Další funkcí je hromadné vkládání obrázků. Funguje na principu, že v textu příspěvku napíšete xml strukturu, kterou plugin nahradí obrázky z databáze.
</p>
<h3>Kdy se to hodí?</h3>
<p>
Když píšete fotoblog a potřebujete do příspěvku vkládat více obrázků najednou. Když máte padesát fotek, které jsou navíc očíslované, tak je můžete vložit buď po jedné, jak to Serendipity umožňují v základu, nebo pomocí jediné řádky s použitím popisovaného pluginu.
</p>
<h3>Příklady</h3>
<h4>Příklad 1 - vkládáme části galerie</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="single" name="pict0034" /&gt;
&lt;media type="single" name="pict0032" /&gt;
&lt;media type="range" prefix="pict00" start="35" stop="52" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
Takto vložíme z galerie "MyHolidays" obrázek "pict0034", po něm obrázek "pict0032" a pak všechny obrázky od "pict0035" do "pict0052".
<ul>
Chování pluginu:
<li>Zobrazuje pouze obrázky, které jsou přítomny v databázi. Takže pokud zrovna obrázky 44,45,48 a 50 v databázi nejsou, pluginu to nevadí a nespadne. Jednoduše tyto obrázky vynechá.</li>
<li>Zachovává pořadí obrázků z xml. Tedy obrázek 34 bude zobrazen před obrázkem 32.</li>
</ul>
</p>
<h4>Příklad 2 - vkládáme celou galerii najednou</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<h3>Důležité</h3>
<p>Plugin je relativně citlivý na (ne)správnost syntaxe xml. Pokud není bezchybná, typicky zapomenete na ukončovací zpětné lomítko v tagu media, můžete vyřadit z činnosti celý blog!!! (prostě není ošetřená kontrola správnosti syntaxe a parser na špatné syntaxi havaruje)</p>
<h3>Přehled xml tagů</h3>
<dl>
<dt>&lt;mediainsert&gt;</dt>
<dd>hlavní kontejner pro vkládané obrázky</dd>
<dt>&lt;gallery&gt;</dt>
<dd>cesta ke galerii, ze které mají být brány obrázky (reltivně k adresáři uploads/ - bez úvodního lomítka a s ukončujícím lomítkem - "MyHolidays" nebo "/MyHolidays/" jsou špatně. Správně je "MyHolidays/".)</dd>
<dt>&lt;media&gt;</dt>
<dd>Určuje, které obrázky mají být vloženy. Na základě atributu "type" je možno vložit obrázky třemi způsoby:
<ul>
<li>"single" - vloží jeden obrázek se jménem zadaným atributem "name"</li>
<li>"gallery" - bez dalších atributů, vloží celou galerii</li>
<li>"range" - vloží číslované obrázky od obrázku "prefix""start" do obrázku "prefix""stop" (viz. příklad 1)</li>
</ul>
</dd>
</dl>
<h3>Změna vzhledu vkládaných obrázků</h3>
<p>
Plugin používá šablonu "plugin_mediainsert.tpl". Její změnou změníte vzhled vkládaných obrázků.</p>
<p>Informace o obrázku jsou uchovány v poli {$plugin_mediainsert_media}, které má tyto části:
<ul>
<li>name - jméno obrázku (název souboru bez přípony)</li>
<li>extension - přípona souboru</li>
<li>realname - celé jméno souboru, to samé jako {$name}.{$extension}</li>
<li>thumbnail_name - název souboru s náhledem dostanete následovně - {$name}.{$thumbnail_name}.{$extension}</li>
<li>path - cesta ke galerii, stejná hodnota, kteoru zadáváte v tagu "gallery"</li>
<li>comment1 - krátký komentář z databáze</li>
<li>width - šířka původního (velkého) obrázku</li>
<li>height - výška původního (velkého) obrázku</li>
<li>thumbwidth - šířka náhledu</li>
<li>thumbheight - výška náhledu</li>
</ul>
</p>
<h2>Rozbalování ZIP archivů</h2>
<h3>K čemu je to dobré</h3>
<p>Kupříkladu když chcete nahrát mnoho souborů najednou. Nemusíte vybírat jednotlivé soubory po jednom (což je zdlouhavé). Prostě je zabalíte do zip archivu, nahrajete tento archiv a ten bude na blogu rozbalen.</p>
<h3>Vlastnosti rozbalování ZIPů</h3>
<p>
<ul>
<li>Soubory z archivu jsou rozbaleny do stejného adresáře, do kterého je nahrán archiv.</li>
<li>Rozbalené soubor (což nemusí být nutně obrázky) jsou vloženy do databáze médií.</li>
<li>Pokud zvolíte volbu "Zadat vlastnosti", rozbalené obrázky se také zorazí pro zadávání vlastností.</li>
<li>Nenahrávejte ZIP archivy s podadersáři. Netestoval jsem to, ale obávám se, že se tyto adresáře nevytvoří a všechny soubory se rozbalí do jednoho adresáře.</li>
<li>Dávejte pozor na velikost ZIP archivu. Na webu máte nastavené určité omezení týkající se maximální velikosti nahrávaného souboru (obvykle to bývá 10MB).</li>
</ul>
</p>
<h2>Automatická změna velikosti obrázků</h2>
<p>Tato funkce automaticky prohledá příspěvek blogu a vyhledá obrázky, které jsou zadány ve formě:</p>
<pre>
&lt;img src="/uploads/mujobrazek.jpg" width="100" height="150" /&gt;
</pre>
<p>Když najde obrázek v tomto formátu (pokud najde obrázek s definovanou výškou a/nebo šířkou), nahradí jeho atribut 'src' (adresa obrázku) odkazem na skript pro změnu velikosti obrázku 'serendipity_admin_image_selector.php'. Tedy přepíše odkaz na něco jako:</p>
<pre>
&lt;img src="http://www.mujblog.cz/serendipity_admin_image_selector.php?serendipity[image]=1&serendipity[disposition]=inline&serendipity[step]=showItem&serendipity[resizeWidth]=100&serendipity[resizeHeight]=150" width="100" height="150" /&gt;
</pre>
<p>Tato vlastnost šetří váš čás, pokud potřebujete použít stejný obrázek ve více rozlišeních a může také ušetřit čas nutný pro stažení obrázků při prohlížení vašeho blogu. Vliv na rychlost blogu je minimální, protože se změna velikosti obrázku provede jenom jednou, při prvním přepisu tagu &lt;img&gt;.
</p>
<h3>Poznámky</h3>
<ol>
<li>Poměr stran obrázku je zachován.</li>
<li>Stačí definovat pouze jeden z atributů 'width' nebo 'height'. Pokud není zadán žádný z nich, obrázek je ignorován a adresa není nahrazena adresou na skript pro změnu velikosti obrázku.</li>
<li>Pokud jsou zadány dohromady jak šířka ('width'), tak výška ('height'), obrázek bude zvětšen/zmenšen při zachování poměrů stran tak, aby se vešel do zadané oblasti.</li>
</ol>
<h2>Autoři</h2>
<p>
Garvin Hicking, Německo - všechno ostatní<br />
Vladimír Ajgl (vlada [at] ajgl [dot] cz), Česká republika, 19.11.2007 - hromadné vkládání obrázků do příspěvků pomocí XML, hromadné nahrávání v ZIP souboru
</p>
<h2>Historie verzí (ChangeLog)</h2>
<ul>
<li>nejnovější verze</li>
<ul>
<li>Dopředná kompatibilita se smarty3</li>
</ul>
<li>verze 0.28</li>
<ul>
<li>Předávání proměnné $eventData do šablony plugin_mediainsert.tpl, pomocí smarty tagu {$plugin_mediainsert_entry}.</li>
</ul>
<li>verze 0.20 [Vladimír Ajgl]</li>
<ul>
<li>Přidána dokumentace (documentation_en.html, documentation_cs.html)</li>
<li>Přidán český překlad</li>
<li>Přidána funkce hromadného vkládání fotek do příspěvků pomocí XML kódu (pouze s PHP5)</li>
</ul>
</ul>
</body>
</html>

View file

@ -1,12 +1,36 @@
<?php #
<?php
/**
* @version
* @author Translator Name <yourmail@example.com>
* DE-Revision: Revision of UTF-8/lang_de.inc.php
* Revised by "nogat" 2014/08/22
*/
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_NAME', 'Erweiterte Optionen für Bildauswahl');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_DESC', 'Ermöglicht erweiterte Optionen beim Einfügen von Bildern aus der Mediendatenbank. [Serendipity >= 0.9]');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_DESC', 'Ermöglicht erweiterte Optionen beim Einfügen von Bildern aus der Mediendatenbank.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET', 'Ziel des Links');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET_JS', 'Popup (via JavaScript, angepasste Größe)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET_ENTRY', 'Isolierter Eintrag');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET_BLANK', 'Popup (via target=_blank)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_QUICKBLOG', 'QuickBlog');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_QUICKBLOG_DESC', 'Wenn Sie bei den folgenden Feldern mindestens einen Titel eintragen, wird das Bild sofort als neuer Blog-Artikel eingestellt. Das Ausgabedesign kann über die Datei quickblog.tpl eingestellt werden.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_MAXWIDTH', 'Maximale Breite des Miniaturbildes (verwirft die Höhenangabe)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_MAXHEIGHT', 'Maximale Höhe des Miniaturbildes (verwirft die Breitenangabe)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_AUTORESIZE', 'Ändert die Bildgröße anhand der Breiten - und Höhenangabe');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_AUTORESIZE_DESC', 'Sendet automatische Größen Ihrer Bilder an den Browser, basierend auf der Breiten/Höhenangabe des IMG-Tag. Dies kann Ihr Leben erleichtern, außerdem die Downloadzeiten verringern und die Serverseitige Performance verbessern. (Hinweis: Die Seitenverhältnisse bleiben erhalten)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FILES', 'ZIP-Archive entpackt');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FILES_BLABLAH', 'Hochgeladene ZIP-Archive entpacken? - Vorgabe für das Formular auf der Bilder-Upload-Seite.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FILES_DESC', 'Hochgeladene ZIP-Archive entpacken?');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_OK', 'ZIP-Archive erfolgreich entpackt!');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FAILED', 'Fehler beim entpacken der ZIP-Archive!');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_IMAGE_FROM_ARCHIVE', 'Bild aus einem ZIP-Archive');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_ADD_TO_DB', 'zur Datenbank hinzugefügt');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_JHEAD', 'jhead nutzen, um EXIF-Daten zu erhalten');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_JHEAD_DESC', 'Überschreibt das Standardverhalten und benutzt externe Funktionen (Calls), um per jhead EXIF-Daten zu erhalten. Nutzen Sie diese Option nur, wenn jhead installiert ist und auch ausgeführt werden kann!');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_IMAGE_SIZE_DESC', 'Wenn Sie die voreingestellte $serendipity[\'thumbSize\'] Größe hier ändern, wird ein zusätzliches Bild in der genannten Größe in der Mediendatenbank erstellt. Dies Image Instanz wird dann im Frontend als Bildvorschau mit entsprechendem Link zum Original Bild in ihrem Blogeintrag benutzt.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_ASOBJECT', 'Objekt-Type ist kein Bild?');

View file

@ -1,121 +1,186 @@
<h1>Serendipity ImageSelectorPlus Plugin Documentation</h1>
<h2>General description</h2>
<p>
ImageSelectorPlus plugin is used to facilitate manipulation with images, especially their insertion into posts.
</p>
<h2>QuickBlog</h2>
<p>
When uploading an image, you can post it directly. Follow the instructions above the QuickBlog form.
</p>
<h3>Modifying the design of QuickBlog post</h3>
<p>
Plugin uses template file "plugin_quickblog.tpl" to display the inserted pictures. So by modifying it, you can change the design of displayed images.</p>
<p>Information about pictures is stored in an array {$quickblog} which has several parts you can use in your template:
<ul>
<li>fullimage - path and filename to the big image</li>
<li>image - path and filename to the thumbnail</li>
<li>body - the body of the post</li>
<li>exif_mode - type of exif information extraction ('internal', 'jhead', 'none'</li>
<li>exif - field of exif information, pleasu use the exif specifications to see the field values - use them like eq. $quickblog.exif.COMMENT or $quickblog.exif.Focal_length</li>
</ul>
</p>
<h2>Multiple image insertions</h2>
<p>
Another functionality of this plugin is multiple image insertion. If you write an xml structure in your entry, this plugin then replaces this xml structure by pictures from your media library.
</p>
<h3>When is it useful?</h3>
<p>
When you write a blog, where you want to include many pictures in your entries. When you have fifty images and these images numbered in an ascending row, it is lengthy to insert them one by one through the images selector. With this plugin, you can insert all of them using on a single line.
</p>
<h3>Examples</h3>
<h4>Example 1 - including parts of gallery</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="single" name="pict0034" /&gt;
&lt;media type="single" name="pict0032" /&gt;
&lt;media type="range" prefix="pict00" start="35" stop="52" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
This example inserts from the directory "MyHolidays" picture "pict0034", then picture "pict0032" and then all pictures from "pict0035" to "pict0052".
<ul>
Plugin features:
<li>It shows only picturse which are in the database. So if pictures 44,45,48 and 50 does not exist, the plugin will not fail. Simply it will not display the non-existing pictures.</li>
<li>It respects order of pictures, so 34 will be displayed before 32.</li>
</ul>
</p>
<h4>Example 2 - including whole gallery at once</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<h3>Important</h3>
<p>The plugin is sensitive to bad xml syntax. So if it is not perfect, for example if you ommit ending backslash in the media tag, it can cause fail to your whole blog!!!</p>
<h3>Review of xml tags</h3>
<dl>
<dt>&lt;mediainsert&gt;</dt>
<dd>general container of media insertion</dd>
<dt>&lt;gallery&gt;</dt>
<dd>from which gallery to choose the images, attribute name gives the path (prom the directory uploads/ - without the first backslash and WITH the final backslash - "MyHolidays" or "/MyHolidays/" is false. Right is "MyHolidays/".)</dd>
<dt>&lt;media&gt;</dt>
<dd>Defines which media to insert, first attribute is "type" and it can have next values:
<ul>
<li>"single" - includes single image given by attribute "name"</li>
<li>"gallery" - without other attributes, includes all images in gallery</li>
<li>"range" - includes numbered images from "prefix""start" to "prefix""stop" (see example1)</li>
</ul>
</dd>
</dl>
<h3>Modifying the design of inserted galleries</h3>
<p>
Plugin uses template file "plugin_mediainsert.tpl" to display the inserted pictures. So by modifying it, you can change the design of displayed images.</p>
<p>Information about pictures is stored in an array {$plugin_mediainsert_media} which has these parts you can use in your template:
<ul>
<li>name - name of picture (filename without extension)</li>
<li>extension - extension of filename</li>
<li>realname - filename, the same as {$name}.{$extension}</li>
<li>thumbnail_name - you can get the thumbnail name by {$name}.{$thumbnail_name}.{$extension}</li>
<li>path - the same value as you provide in gallery tag</li>
<li>comment1 - comment from database</li>
<li>width - width of original image</li>
<li>height - height of original image</li>
<li>thumbwidth - width of thumbnail</li>
<li>thumbheight - height of thumbnail</li>
</ul>
</p>
<h2>Unzipping ZIP archives</h2>
<h3>What it is good for</h3>
<p>Typically when you want to upload many pictures at once. You need not to select every image discinctly. Just pack them in the ZIP archive, upload this archive and it will be unzipped on your blog.</p>
<h3>Features of unzipping</h3>
<p>
<ul>
<li>Files from archive are unzipped into the same directory, where the archive is uploaded.</li>
<li>Unzipped files (not necessarily images) will be inserted in the media database.</li>
<li>When selecting "Edit properties", unzipped images will be displayed.</li>
<li>Do not make zip files with subdirectories. I didn't tested it, but I am afraid it will not unzip the directories, it will put all files in the target directory.</li>
<li>Take into account the size of the archive. You have some limitations on maximal upload file size (typically 10MB).</li>
</ul>
</p>
<h2>Authors</h2>
<p>Garvin Hicking, Germany <br />
Vladimír Ajgl (vlada [at] ajgl [dot] cz), Czech Republic, 2007-11-19
</p>
<h1>Serendipity ImageSelectorPlus Plugin Beschreibung</h1>
<h2>Allgemeine Beschreibung</h2>
<p>
ImageSelectorPlus Plugin wird verwendet, um Änderungen mit Bildern zu erleichtern, insbesondere bei der Einbindung in Artikel.
</p>
<h2>QuickBlog</h2>
<p>
Beim Hochladen eines Bildes können Sie es direkt veröffentlichen. Befolgen Sie die Anweisungen über dem QuickBlog Eingabefeld.
</p>
<h3>Ändern des Aussehens des QuickBlog Eingabefeldes</h3>
<p>
Das Plugin verwendet eine Template-Datei "plugin_quickblog.tpl", um die eingefügten Bilder anzuzeigen. Indem Sie diese Datei bearbeiten, können Sie das Design der angezeigten Bilder ändern.
</p>
<p>
Informationen zu Bildern werden in einem Array {$quickblog} gehalten, welches aus mehreren Teilen besteht, die Sie in Ihrer Vorlage verwenden können:
<ul>
<li>fullimage - Pfad und Dateiname zum großen Bild</li>
<li>image - Pfad und Dateiname zum Vorschaubild (Thumbnail)</li>
<li>body - the body of the post</li>
<li>exif_mode - Art des Auslesens der Exif-Information ('interne', 'jhead', 'none')</li>
<li>exif - Bereich der Exif-Informationen, bitte verwenden die EXiF-Daten, um die Feldwerte zu sehen - nutzen sie die in der Form wie $quickblog.exif.COMMENT oder $quickblog.exif.Focal_length</li>
</ul>
</p>
<h2>Mehrfaches einbinden von Bildern</h2>
<p>
Another functionality of this plugin is multiple image insertion. If you write an xml structure in your entry, this plugin then replaces this xml structure by pictures from your media library.
</p>
<h3>When is it useful?</h3>
<p>
When you write a blog, where you want to include many pictures in your entries. When you have fifty images and these images numbered in an ascending row, it is lengthy to insert them one by one through the images selector. With this plugin, you can insert all of them using on a single line.
</p>
<h3>Examples</h3>
<h4>Example 1 - including parts of gallery</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="single" name="pict0034" /&gt;
&lt;media type="single" name="pict0032" /&gt;
&lt;media type="range" prefix="pict00" start="35" stop="52" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
This example inserts from the directory "MyHolidays" picture "pict0034", then picture "pict0032" and then all pictures from "pict0035" to "pict0052".
<ul>
Plugin features:
<li>It shows only picturse which are in the database. So if pictures 44,45,48 and 50 does not exist, the plugin will not fail. Simply it will not display the non-existing pictures.</li>
<li>It respects order of pictures, so 34 will be displayed before 32.</li>
</ul>
</p>
<h4>Example 2 - including whole gallery at once</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<h4>Beispiel 3 - Versteckt Vorschaubilder nach einer bestimmten Bildnummer</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;media type="hideafter" nr="2" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
In diesem Beispiel werden alle Bilder aus dem Verzeichnis "MyHolidays" angezeigt, aber ab dem 3. Bild werden alle folgenden versteckt.
<ul>
Wozu sollte das nützlich sein?
<li>Wenn Sie ein Leuchtkasten (lightbox) Plugin benutzen, welches sich in alle Artikelbilder einbindet, könnten eine Menge an Vorschaubildern sichtbar werden.</li>
<li>Mit hideafter können Sie die Auflistung begrenzen. Der Leuchtkasten funktioniert dennoch mit allen Bildern - auch mit den nicht sichtbaren!</li>
</ul>
</p>
<h4>Beispiel 4 - Erzeugt einen Zeilenumbruch nach einer bestimmten Bildnummer</h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;media type="hideafter" nr="15" /&gt;
&lt;media type="picperrow" pr="3" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
In diesem Beispiel werden alle Bilder aus dem Verzeichnis "MyHolidays" angezeigt, ab dem 15. Bild werden alle folgenden versteckt.
Außerdem erfolgt eine Anordnung in 5 Reihen (15 / 3 = 5), es sind also 3 Bilder pro Reihe sichtbar in 5 Spalten.
</p>
<h3>Important</h3>
<p>The plugin is sensitive to bad xml syntax. So if it is not perfect, for example if you ommit ending backslash in the media tag, it can cause fail to your whole blog!!!</p>
<h3>Review of xml tags</h3>
<dl>
<dt>&lt;mediainsert&gt;</dt>
<dd>general container of media insertion</dd>
<dt>&lt;gallery&gt;</dt>
<dd>from which gallery to choose the images, attribute name gives the path (prom the directory uploads/ - without the first backslash and WITH the final backslash - "MyHolidays" or "/MyHolidays/" is false. Right is "MyHolidays/".)</dd>
<dt>&lt;media&gt;</dt>
<dd>Defines which media to insert, first attribute is "type" and it can have next values:
<ul>
<li>"single" - includes single image given by attribute "name"</li>
<li>"gallery" - without other attributes, includes all images in gallery</li>
<li>"range" - includes numbered images from "prefix""start" to "prefix""stop" (see example1)</li>
<li>"hideafter" - Versteckt Bilder nach einer bestimmten Anzahl an Bildern (Beispiel 3)</li>
<li>"picperrow" - Erzeugt nach einem Bild einen Umbruch, somit können Die Vorschaubilder in Zeilen aufgeteilt werden (Beispiel 4)</li>
</ul>
</dd>
</dl>
<h3>Modifying the design of inserted galleries</h3>
<p>
Plugin uses template file "plugin_mediainsert.tpl" to display the inserted pictures. So by modifying it, you can change the design of displayed images.</p>
<p>Information about pictures is stored in an array {$plugin_mediainsert_media} which has these parts you can use in your template:
<ul>
<li>name - name of picture (filename without extension)</li>
<li>extension - extension of filename</li>
<li>realname - filename, the same as {$name}.{$extension}</li>
<li>thumbnail_name - you can get the thumbnail name by {$name}.{$thumbnail_name}.{$extension}</li>
<li>path - the same value as you provide in gallery tag</li>
<li>comment1 - comment from database</li>
<li>width - width of original image</li>
<li>height - height of original image</li>
<li>thumbwidth - width of thumbnail</li>
<li>thumbheight - height of thumbnail</li>
</ul>
</p>
<h2>Unzipping ZIP archives</h2>
<h3>What it is good for</h3>
<p>Typically when you want to upload many pictures at once. You need not to select every image discinctly. Just pack them in the ZIP archive, upload this archive and it will be unzipped on your blog.</p>
<h3>Features of unzipping</h3>
<p>
<ul>
<li>Files from archive are unzipped into the same directory, where the archive is uploaded.</li>
<li>Unzipped files (not necessarily images) will be inserted in the media database.</li>
<li>When selecting "Edit properties", unzipped images will be displayed.</li>
<li>Do not make zip files with subdirectories. I didn't tested it, but I am afraid it will not unzip the directories, it will put all files in the target directory.</li>
<li>Take into account the size of the archive. You have some limitations on maximal upload file size (typically 10MB).</li>
</ul>
</p>
<h2>Auto Resizing of Images</h2>
<p>This feature will automatically search through your blog post for images in the form:</p>
<pre>
&lt;img src="/uploads/myimage.jpg" width="100" height="150" /&gt;
</pre>
<p>When it finds an image tag in this form it will replace the value of 'src' attribute with the path
to the image resizing script, serendipity_admin_image_selector.php. The end result would be something
like this:</p>
<pre>
&lt;img src="http://domain.com/serendipity_admin_image_selector.php?serendipity[image]=1&serendipity[disposition]=inline&serendipity[step]=showItem&serendipity[resizeWidth]=100&serendipity[resizeHeight]=150" width="100" height="150" /&gt;
</pre>
<p>This saves you time if you need to use images at multiple resolutions, and can also reduce
download times for users. The performance hit is minimal as the image resize is only done once,
as is the parsing of img tags.</p>
<h3>Notes</h3>
<ol>
<li>Image aspect ratios are maintained.</li>
<li>Only the width or height attribute needs to be specified. If neither is specified then the image tag is ignored</li>
<li>If both the width and height attributes are specified the image will be scaled to fit within this area while maintaining the aspect ratio</li>
</ol>
<h2>Authors</h2>
<p>Garvin Hicking, Germany <br />
Vladimir Ajgl (vlada [at] ajgl [dot] cz), Czech Republic, 2007-11-19 <br />
User "nogad", http://board.s9y.org/viewtopic.php?f=4&t=20058, 2014-08-22 <br />
Ian, 2014-09-04
</p>

View file

@ -60,6 +60,37 @@ Another functionality of this plugin is multiple image insertion. If you write a
&lt;media type="gallery" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<h4>Example 3 - hides preview pictures after specified image number </h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;media type="hideafter" nr="2" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
This example inserts all pictures from directory "MyHolidays", but disables visiblity from picture number 3.
<ul>
Why its useful?
<li>If you are using a lightbox plugin, which inserts in all article images, there may be a lot of preview images.</li>
<li>With hideafter you can stop the visibility of a huge list of preview pictures. But the lightbox is still working!</li>
</ul>
</p>
<h4>Example 4 - Break floating by newline after certain number of images </h4>
<code><pre>
&lt;mediainsert&gt;
&lt;gallery name="MyHolidays/" /&gt;
&lt;media type="gallery" /&gt;
&lt;media type="hideafter" nr="15" /&gt;
&lt;media type="picperrow" pr="3" /&gt;
&lt;/mediainsert&gt;
</pre></code>
<p>
This example inserts all pictures from directory "MyHolidays", but disables visiblity from picture number 15.
Moreover, an arrangement in 5 rows (15/3 = 5), so there are 3 images per row visible in 5 columns.
</p>
<h3>Important</h3>
<p>The plugin is sensitive to bad xml syntax. So if it is not perfect, for example if you ommit ending backslash in the media tag, it can cause fail to your whole blog!!!</p>
@ -78,6 +109,8 @@ Another functionality of this plugin is multiple image insertion. If you write a
<li>"single" - includes single image given by attribute "name"</li>
<li>"gallery" - without other attributes, includes all images in gallery</li>
<li>"range" - includes numbered images from "prefix""start" to "prefix""stop" (see example1)</li>
<li>"hideafter" - hides preview pictures after "nr" ("lastvisiblenumber") (see example3)</li>
<li>"picperrow" - Generate a break for an amount by image, thus the shown thumbnails are divided into rows (Example 4)</li>
</ul>
</dd>
</dl>
@ -115,35 +148,37 @@ Another functionality of this plugin is multiple image insertion. If you write a
</ul>
</p>
<h2>Auto Resizing of Images</h2>
<p>This feature will automatically search through your blog post for images in the form:</p>
<pre>
&lt;img src="/uploads/myimage.jpg" width="100" height="150" /&gt;
</pre>
<p>When it finds an image tag in this form it will replace the value of 'src' attribute with the path
to the image resizing script, serendipity_admin_image_selector.php. The end result would be something
like this:</p>
<pre>
&lt;img src="http://domain.com/serendipity_admin_image_selector.php?serendipity[image]=1&serendipity[disposition]=inline&serendipity[step]=showItem&serendipity[resizeWidth]=100&serendipity[resizeHeight]=150" width="100" height="150" /&gt;
</pre>
<p>This saves you time if you need to use images at multiple resolutions, and can also reduce
download times for users. The performance hit is minimal as the image resize is only done once,
as is the parsing of img tags.</p>
<h3>Notes</h3>
<ol>
<li>Image aspect ratios are maintained.</li>
<li>Only the width or height attribute needs to be specified. If neither is specified then the image tag is ignored</li>
<li>If both the width and height attributes are specified the image will be scaled to fit within this area while maintaining the aspect ratio</li>
</ol>
<h2>Auto Resizing of Images</h2>
<p>This feature will automatically search through your blog post for images in the form:</p>
<pre>
&lt;img src="/uploads/myimage.jpg" width="100" height="150" /&gt;
</pre>
<p>When it finds an image tag in this form it will replace the value of 'src' attribute with the path
to the image resizing script, serendipity_admin_image_selector.php. The end result would be something
like this:</p>
<pre>
&lt;img src="http://domain.com/serendipity_admin_image_selector.php?serendipity[image]=1&serendipity[disposition]=inline&serendipity[step]=showItem&serendipity[resizeWidth]=100&serendipity[resizeHeight]=150" width="100" height="150" /&gt;
</pre>
<p>This saves you time if you need to use images at multiple resolutions, and can also reduce
download times for users. The performance hit is minimal as the image resize is only done once,
as is the parsing of img tags.</p>
<h3>Notes</h3>
<ol>
<li>Image aspect ratios are maintained.</li>
<li>Only the width or height attribute needs to be specified. If neither is specified then the image tag is ignored</li>
<li>If both the width and height attributes are specified the image will be scaled to fit within this area while maintaining the aspect ratio</li>
</ol>
<h2>Authors</h2>
<p>Garvin Hicking, Germany <br />
Vladim¡r Ajgl (vlada [at] ajgl [dot] cz), Czech Republic, 2007-11-19
Vladimir Ajgl (vlada [at] ajgl [dot] cz), Czech Republic, 2007-11-19 <br />
User "nogad", http://board.s9y.org/viewtopic.php?f=4&t=20058, 2014-08-22 <br />
Ian, 2014-09-04
</p>

View file

@ -1,12 +1,36 @@
<?php #
<?php
/**
* @version
* @author Translator Name <yourmail@example.com>
* DE-Revision: Revision of lang_de.inc.php
* Revised by "nogat" 2014/08/22
*/
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_NAME', 'Erweiterte Optionen für Bildauswahl');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_DESC', 'Ermöglicht erweiterte Optionen beim Einfügen von Bildern aus der Mediendatenbank. [Serendipity >= 0.9]');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_DESC', 'Ermöglicht erweiterte Optionen beim Einfügen von Bildern aus der Mediendatenbank.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET', 'Ziel des Links');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET_JS', 'Popup (via JavaScript, angepasste Größe)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET_ENTRY', 'Isolierter Eintrag');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_TARGET_BLANK', 'Popup (via target=_blank)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_QUICKBLOG', 'QuickBlog');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_QUICKBLOG_DESC', 'Wenn Sie bei den folgenden Feldern mindestens einen Titel eintragen, wird das Bild sofort als neuer Blog-Artikel eingestellt. Das Ausgabedesign kann über die Datei quickblog.tpl eingestellt werden.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_MAXWIDTH', 'Maximale Breite des Miniaturbildes (verwirft die Höhenangabe)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_MAXHEIGHT', 'Maximale Höhe des Miniaturbildes (verwirft die Breitenangabe)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_AUTORESIZE', 'Ändert die Bildgröße anhand der Breiten - und Höhenangabe');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_AUTORESIZE_DESC', 'Sendet automatische Größen Ihrer Bilder an den Browser, basierend auf der Breiten/Höhenangabe des IMG-Tag. Dies kann Ihr Leben erleichtern, außerdem die Downloadzeiten verringern und die Serverseitige Performance verbessern. (Hinweis: Die Seitenverhältnisse bleiben erhalten)');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FILES', 'ZIP-Archive entpackt');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FILES_BLABLAH', 'Hochgeladene ZIP-Archive entpacken? - Vorgabe für das Formular auf der Bilder-Upload-Seite.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FILES_DESC', 'Hochgeladene ZIP-Archive entpacken?');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_OK', 'ZIP-Archive erfolgreich entpackt!');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_FAILED', 'Fehler beim entpacken der ZIP-Archive!');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_IMAGE_FROM_ARCHIVE', 'Bild aus einem ZIP-Archive');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_ADD_TO_DB', 'zur Datenbank hinzugefügt');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_JHEAD', 'jhead nutzen, um EXIF-Daten zu erhalten');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_JHEAD_DESC', 'Überschreibt das Standardverhalten und benutzt externe Funktionen (Calls), um per jhead EXIF-Daten zu erhalten. Nutzen Sie diese Option nur, wenn jhead installiert ist und auch ausgeführt werden kann!');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_IMAGE_SIZE_DESC', 'Wenn Sie die voreingestellte $serendipity[\'thumbSize\'] Größe hier ändern, wird ein zusätzliches Bild in der genannten Größe in der Mediendatenbank erstellt. Dies Image Instanz wird dann im Frontend als Bildvorschau mit entsprechendem Link zum Original Bild in ihrem Blogeintrag benutzt.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_ASOBJECT', 'Objekt-Type ist kein Bild?');

View file

@ -1,10 +1,10 @@
<?php #
/**
* @version
* @version
* @author Translator Name <yourmail@example.com>
* EN-Revision: Revision of lang_en.inc.php
* Revised by Vladimir Ajgl <vlada@ajgl.cz> 2007/11/25
* Revised by Vladimir Ajgl <vlada@ajgl.cz> 2007/11/25
*/
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_NAME', 'Extended options for media manager');
@ -29,7 +29,8 @@
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_UNZIP_ADD_TO_DB', 'added to database');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_JHEAD', 'Use jhead to obtain EXIF data');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_JHEAD_DESC', 'Override the default behaviour and use external calls to jhead to obtain EXIF data. Choose this option only if jhead is installed and can be executed.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_JHEAD_DESC', 'Override the default behaviour and use external calls to jhead to obtain EXIF data. Choose this option only if jhead is installed and can be executed.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_IMAGE_SIZE_DESC', 'Changing this default $serendipity[\'thumbSize\'] to another value, will add an additional and resized copy of that image to the MediaLibrary. This instance is then used as the preview thumbnail image in your frontend blog entry, linking to the origin image.');
@define('PLUGIN_EVENT_IMAGESELECTORPLUS_ASOBJECT', 'Non-image object?');

View file

@ -1,8 +1,18 @@
<div class="serendipity_mediainsert_gallery">
{foreach from=$plugin_mediainsert_media item="medium"}
{foreach from=$plugin_mediainsert_media item="medium" name="pmd"}
{if isset($plugin_mediainsert_hideafter) && isset($plugin_mediainsert_picperrow) && $smarty.foreach.pmd.iteration <= $plugin_mediainsert_hideafter}
{if !$smarty.foreach.pmd.first && $plugin_mediainsert_picperrow > 0 && $smarty.foreach.pmd.index % $plugin_mediainsert_picperrow == 0}
<div style="clear:both">&nbsp;</div>
{/if}
{/if}
{if isset($plugin_mediainsert_hideafter) && $smarty.foreach.pmd.iteration > $plugin_mediainsert_hideafter}
<div class="serendipity_imageComment_left" style="width: 0px; height: 0px; display: none">
{else}
<div class="serendipity_imageComment_left" style="width: {$medium.thumbwidth}px">
{/if}
<div class="serendipity_imageComment_img">
<a class="serendipity_image_link" href="{$serendipityHTTPPath}uploads/{$medium.path}{$medium.realname}">
<!-- s9ymdb:{$medium.id} -->

View file

@ -26,7 +26,7 @@ class serendipity_event_imageselectorplus extends serendipity_event
$propbag->add('description', PLUGIN_EVENT_IMAGESELECTORPLUS_DESC);
$propbag->add('stackable', false);
$propbag->add('author', 'Garvin Hicking, Vladimir Ajgl, Adam Charnock, Ian');
$propbag->add('version', '0.41');
$propbag->add('version', '0.42');
$propbag->add('requirements', array(
'serendipity' => '1.3',
'smarty' => '2.6.7',
@ -246,7 +246,7 @@ class serendipity_event_imageselectorplus extends serendipity_event
if (isset($hooks[$event])) {
switch($event) {
case 'backend_image_addform':
if ($serendipity['version'][0] < '2') {
if ($serendipity['version'][0] < 2) {
if (class_exists('ZipArchive')) {
$checkedY = "";
$checkedN = "";
@ -367,7 +367,7 @@ class serendipity_event_imageselectorplus extends serendipity_event
?>
<script src="<?php echo $serendipity['serendipityHTTPPath']; ?>htmlarea/ckeditor/ckeditor/ckeditor.js"></script>
<?php
}
} // just add a simple basic toolbar, since we cannot use embedded plugins here
?>
<script>
CKEDITOR.replace( 'nuggets2',
@ -641,7 +641,7 @@ class serendipity_event_imageselectorplus extends serendipity_event
return true;
}
if ($serendipity['version'][0] > '1') {
if ($serendipity['version'][0] > 1) {
return true;
}
@ -691,7 +691,7 @@ class serendipity_event_imageselectorplus extends serendipity_event
break;
case 'css_backend':
if ($serendipity['version'][0] > '1') {
if ($serendipity['version'][0] > 1) {
?>
#imageselectorplus .radio_field input {
@ -735,12 +735,18 @@ class serendipity_event_imageselectorplus extends serendipity_event
#content .serendipity_quickblog_image {
border: medium none transparent;
}
.serendipity_mediainsert_gallery {
border: 1px solid #C0C0C0;
margin: 0px;
overflow: auto;
padding: 0.4em;
}
<?php
break;
case 'frontend_image_selector':
if ($serendipity['version'][0] < '2') {
if ($serendipity['version'][0] < 2) {
$eventData['finishJSFunction'] = 'serendipity_imageSelectorPlus_done(\'' . htmlspecialchars($serendipity['GET']['textarea']) . '\')';
} else {
$eventData['finishJSFunction'] = 'serendipity.serendipity_imageSelector_done(\'' . htmlspecialchars($serendipity['GET']['textarea']) . '\')';
@ -835,7 +841,7 @@ class serendipity_event_imageselectorplus extends serendipity_event
}
$quickblog = array(
'html5' => ($serendipity['wysiwyg'] || $serendipity['version'][0] > '1') ? true : false,
'html5' => ($serendipity['wysiwyg'] || $serendipity['version'][0] > 1) ? true : false,
'image' => $http_outfile,
'fullimage' => $http_infile,
'body' => preg_replace('@(<!--quickblog:.+-->)@imsU', '', $body),
@ -903,6 +909,14 @@ class serendipity_event_imageselectorplus extends serendipity_event
$whole_gallery = true;
break;
case 'hideafter':
$hideafter = intval($medium['nr']);
break;
case 'picperrow':
$picperrow = intval($medium['pr']);
break;
default:
break;
}
@ -971,8 +985,15 @@ class serendipity_event_imageselectorplus extends serendipity_event
$tfile = dirname(__FILE__) . '/plugin_mediainsert.tpl';
}
$serendipity['smarty']->assign('plugin_mediainsert_media', $t);
$serendipity['smarty']->assign('plugin_mediainsert_entry', $eventData);
$serendipity['smarty']->assign(
array(
'plugin_mediainsert_media' => $t,
'plugin_mediainsert_entry' => $eventData,
'plugin_mediainsert_hideafter' => $hideafter,
'plugin_mediainsert_picperrow' => $picperrow
)
);
$content = $this->parseTemplate($tfile);
} else {