]> git.mjollnir.org Git - s9y.git/commitdiff
Add detail pane for viewing media
authorgarvinhicking <garvinhicking>
Fri, 21 Apr 2006 10:56:07 +0000 (10:56 +0000)
committergarvinhicking <garvinhicking>
Fri, 21 Apr 2006 10:56:07 +0000 (10:56 +0000)
66 files changed:
deployment/serendipity_editor.js
docs/NEWS
include/admin/images.inc.php
include/functions_images.inc.php
lang/UTF-8/serendipity_lang_bg.inc.php
lang/UTF-8/serendipity_lang_cn.inc.php
lang/UTF-8/serendipity_lang_cs.inc.php
lang/UTF-8/serendipity_lang_cz.inc.php
lang/UTF-8/serendipity_lang_da.inc.php
lang/UTF-8/serendipity_lang_de.inc.php
lang/UTF-8/serendipity_lang_en.inc.php
lang/UTF-8/serendipity_lang_es.inc.php
lang/UTF-8/serendipity_lang_fa.inc.php
lang/UTF-8/serendipity_lang_fi.inc.php
lang/UTF-8/serendipity_lang_fr.inc.php
lang/UTF-8/serendipity_lang_hu.inc.php
lang/UTF-8/serendipity_lang_is.inc.php
lang/UTF-8/serendipity_lang_it.inc.php
lang/UTF-8/serendipity_lang_ja.inc.php
lang/UTF-8/serendipity_lang_ko.inc.php
lang/UTF-8/serendipity_lang_nl.inc.php
lang/UTF-8/serendipity_lang_no.inc.php
lang/UTF-8/serendipity_lang_pt.inc.php
lang/UTF-8/serendipity_lang_pt_PT.inc.php
lang/UTF-8/serendipity_lang_ro.inc.php
lang/UTF-8/serendipity_lang_ru.inc.php
lang/UTF-8/serendipity_lang_se.inc.php
lang/UTF-8/serendipity_lang_ta.inc.php
lang/UTF-8/serendipity_lang_tn.inc.php
lang/UTF-8/serendipity_lang_tr.inc.php
lang/UTF-8/serendipity_lang_tw.inc.php
lang/UTF-8/serendipity_lang_zh.inc.php
lang/addlang.txt
lang/plugin_lang.php
lang/serendipity_lang_bg.inc.php
lang/serendipity_lang_cn.inc.php
lang/serendipity_lang_cs.inc.php
lang/serendipity_lang_cz.inc.php
lang/serendipity_lang_da.inc.php
lang/serendipity_lang_de.inc.php
lang/serendipity_lang_en.inc.php
lang/serendipity_lang_es.inc.php
lang/serendipity_lang_fa.inc.php
lang/serendipity_lang_fi.inc.php
lang/serendipity_lang_fr.inc.php
lang/serendipity_lang_hu.inc.php
lang/serendipity_lang_is.inc.php
lang/serendipity_lang_it.inc.php
lang/serendipity_lang_ja.inc.php
lang/serendipity_lang_ko.inc.php
lang/serendipity_lang_nl.inc.php
lang/serendipity_lang_no.inc.php
lang/serendipity_lang_pt.inc.php
lang/serendipity_lang_pt_PT.inc.php
lang/serendipity_lang_ro.inc.php
lang/serendipity_lang_ru.inc.php
lang/serendipity_lang_se.inc.php
lang/serendipity_lang_ta.inc.php
lang/serendipity_lang_tn.inc.php
lang/serendipity_lang_tr.inc.php
lang/serendipity_lang_tw.inc.php
lang/serendipity_lang_zh.inc.php
serendipity_admin_image_selector.php
serendipity_editor.js
templates/default/admin/media_choose.tpl
templates/default/admin/media_showitem.tpl [new file with mode: 0644]

index d8c6c72b29f59746cb12e04e545edc2027ef1e42..a853e0b21d5b47cde49530c4c8a8b8b9f1562438 100644 (file)
@@ -229,6 +229,10 @@ function serendipity_imageSelector_done(textarea)
     if (f['imgID']) {
         imgID = f['imgID'].value;
     }
+    baseURL = '';
+    if (f['baseURL']) {
+        baseURL = f['baseURL'].value;
+    }
 
     floating = 'center';
     if (f['serendipity[align]'][0].checked == true) {
@@ -242,7 +246,32 @@ function serendipity_imageSelector_done(textarea)
     }
 
     if (f['serendipity[isLink]'][1].checked == true) {
-        insert = "<a class='serendipity_image_link' href='" + f['serendipity[url]'].value + "'>" + img + "</a>";
+        if (f['serendipity[target]'].selectedIndex) {
+            targetval = f['serendipity[target]'].options[f['serendipity[target]'].selectedIndex].value;
+        } else {
+            targetval = '';
+        }
+
+        prepend   = '';
+        ilink     = f['serendipity[url]'].value;
+        if (!targetval || targetval == 'none') {
+            itarget = '';
+        } else if (targetval == 'js') {
+            itarget = ' onclick="F1 = window.open(\'' + f['serendipity[url]'].value + '\',\'Zoom\',\''
+                    + 'height=' + (parseInt(f['imgHeight'].value) + 15) + ','
+                    + 'width='  + (parseInt(f['imgWidth'].value)  + 15) + ','
+                    + 'top='    + (screen.height - f['imgHeight'].value) /2 + ','
+                    + 'left='   + (screen.width  - f['imgWidth'].value)  /2 + ','
+                    + 'toolbar=no,menubar=no,location=no,resize=1,resizable=1,scrollbars=yes\'); return false;"';
+        } else if (targetval == '_blank') {
+            itarget = ' target="_blank"';
+        } else if (targetval == 'plugin') {
+            itarget = ' id="s9yisphref' + imgID + '"';
+            prepend = '<a title="' + ilink + '" id="s9yisp' + imgID + '"></a>';
+            ilink   = baseURL + 'serendipity_admin_image_selector.php?serendipity[step]=showItem&amp;serendipity[image]=' + imgID;
+        }
+
+        insert = prepend + "<a class='serendipity_image_link' href='" + ilink + "'" + itarget + ">" + img + "</a>";
     } else {
         insert = img;
     }
index d53857c65fbb8393de733a442df7a31a6d7bf9de..c145e952950e1fc38b16447a3f17a2406522d400 100644 (file)
--- a/docs/NEWS
+++ b/docs/NEWS
@@ -38,10 +38,12 @@ Version 1.1-alpha4()
          - Search/Filter for specific properties/keywords.
          - Enhanced media filter for keywords
          - Use entered comments in the "You choose..." picking page
+         - Integrate new page for viewing images with media properties
+           through serendipity_admin_image_selector.php?serendipity[image]=X
+         - Integrate imageselectorplus plugin options for giving a target
+           to links
 
      TODO:
-         - Store uploader authorid (new DB column required)
-
          - New option for image_Selector to save a specific sized version
            (?fid=XXX&targetSize=XX)
          - Track referrers by image selector and store as property
index ca59240ac82578f9daa35590c18fa3ae4dc1ce0a..a32f9ac943099ed1361665830a1e3b4fe051f722 100644 (file)
@@ -321,6 +321,15 @@ switch ($serendipity['GET']['adminAction']) {
 
     if (isset($_REQUEST['go_properties'])) {
         serendipity_showPropertyForm($new_media);
+    } else {
+        $hidden = array(
+            'author'   => $serendipity['serendipityUser'],
+            'authorid' => $serendipity['authorid']
+        );
+
+        foreach($new_media AS $nm) {
+            serendipity_insertMediaProperty('base_hidden', '', $nm['image_id'], $hidden);
+        }
     }
     break;
 
index ef88587f3f5dcbfddb753b0e939446baa910d5aa..57a2e0204bf39fa7870b5a9aab0bbddd9c17cf42 100644 (file)
@@ -84,7 +84,7 @@ function serendipity_fetchImagesFromDatabase($start=0, $limit=0, &$total, $order
         $keywords[$i] = serendipity_db_escape_string($keyword);
     }
 
-    $join_properties = $join_keywords = $join_filterproperties = false;
+    $join_properties = $join_keywords = $join_filterproperties = $join_hiddenproperties = false;
     if (count($keywords) > 0) {
         $where_sql .= " AND (mk.property IN ('" . implode("', '", $keywords) . "'))\n";
         $join_keywords = true;
@@ -111,6 +111,13 @@ function serendipity_fetchImagesFromDatabase($start=0, $limit=0, &$total, $order
             } else {
                 $where_sql .= " AND ($f >= " . (int)$fval['from'] . " AND $f <= " . (int)$fval['to'] . ")\n";
             }
+        } elseif ($f == 'i.authorid') {
+            $where_sql .= " AND (
+                                    (hp.property = 'authorid' AND hp.value = " . (int)$fval . ")
+                                    OR
+                                    (i.authorid = " . (int)$fval . ")
+                                )\n";
+            $join_hiddenproperties = true;
         } elseif ($orderfields[$f]['type'] == 'int') {
             if (substr($f, 0, 3) === 'bp.') {
                 $realf = substr($f, 3);
@@ -162,6 +169,11 @@ function serendipity_fetchImagesFromDatabase($start=0, $limit=0, &$total, $order
                                         ON (bp2.mediaid = i.id AND bp2.property_group = 'base_property')\n";
     }
 
+    if ($join_hiddenproperties) {
+        $cond['joins'] .= "\n LEFT OUTER JOIN {$serendipity['dbPrefix']}mediaproperties AS hp
+                                        ON (hp.mediaid = i.id AND hp.property_group = 'base_hidden')\n";
+    }
+
     if ($serendipity['dbType'] == 'postgres') {
         $cond['group']    = '';
         $cond['distinct'] = 'DISTINCT';
@@ -190,7 +202,7 @@ function serendipity_fetchImagesFromDatabase($start=0, $limit=0, &$total, $order
         return array();
     }
 
-    $total_query = "SELECT count(i.id)
+    $total_query = "SELECT count(DISTINCT i.id)
                            $basequery";
     $total_rs = serendipity_db_query($total_query, true, 'num');
     if (is_array($total_rs)) {
@@ -2019,9 +2031,6 @@ function serendipity_showPropertyForm(&$new_media, $keywordsPerBlock = 3, $is_ed
     $mirror = array();
     serendipity_checkPropertyAccess($new_media, $mirror, 'read');
 
-    $dprops   = explode(';', $serendipity['mediaProperties']);
-    $keywords = explode(';', $serendipity['mediaKeywords']);
-
     $editform_hidden = '';
     if (isset($GLOBALS['image_selector_addvars']) && is_array($GLOBALS['image_selector_addvars'])) {
         // These variables may come from serendipity_admin_image_selector.php to show embedded upload form
@@ -2030,6 +2039,9 @@ function serendipity_showPropertyForm(&$new_media, $keywordsPerBlock = 3, $is_ed
         }
     }
 
+    $dprops   = explode(';', $serendipity['mediaProperties']);
+    $keywords = explode(';', $serendipity['mediaKeywords']);
+
     $now  = serendipity_serverOffsetHour();
     $show = array();
     foreach($new_media AS $idx => $media) {
@@ -2046,128 +2058,154 @@ function serendipity_showPropertyForm(&$new_media, $keywordsPerBlock = 3, $is_ed
             serendipity_plugin_api::hook_event('media_getproperties_cached', $show[$idx]['metadata'], $show[$idx]['realfile']);
         }
 
-        foreach($dprops AS $prop) {
-            $type = 'input';
-            $parts = explode(':', trim($prop));
+        serendipity_parseMediaProperties($dprops, $keywords, $show[$idx], $props, $keywordsPerBlock, $is_edit);
+    }
 
-            if (in_array('MULTI', $parts)) {
-                $type = 'textarea';
-            }
+    $smarty_vars = array(
+        'is_edit'           => $is_edit,
+        'editform_hidden'   => $editform_hidden,
+        'keywordsPerBlock'  => $keywordsPerBlock,
+        'keywords'          => $keywords,
+        'dprops'            => $dprops
+    );
+    return serendipity_showMedia(
+        $show,
+        $mirror,
+        $url,
+        false,
+        1,
+        false,
+        $smarty_vars);
+}
 
-            if (preg_match('@(AUDIO|VIDEO|DOCUMENT|IMAGE|ARCHIVE|BINARY)@i', $prop)) {
-                $show_item = false;
-                if ($show[$idx]['mediatype'] == 'video' && in_array('VIDEO', $parts)) {
-                    $show_item = true;
-                }
+/**
+ * Parse/Convert properties
+ *
+ * @param  array    Holds the property key array
+ * @param  array    Holds the keyword key array
+ * @param  int      Holds the media metadata
+ * @param  int      Holds the media properties
+ * @param  int      How many keyword checkboxes to display next to each other?
+ * @param  boolean  Can existing data be modified?
+ * @return boolean
+ *
+ */
+function serendipity_parseMediaProperties(&$dprops, &$keywords, &$media, &$props, $keywordsPerBlock, $is_edit) {
+    global $serendipity;
 
-                if ($show[$idx]['mediatype'] == 'audio'  && in_array('AUDIO', $parts)) {
-                    $show_item = true;
-                }
+    if (!is_array($dprops)) {
+        $dprops   = explode(';', $serendipity['mediaProperties']);
+    }
+    if (!is_array($keywords)) {
+        $keywords = explode(';', $serendipity['mediaKeywords']);
+    }
 
-                if ($show[$idx]['mediatype'] == 'image'  && in_array('IMAGE', $parts)) {
-                    $show_item = true;
-                }
+    foreach($dprops AS $prop) {
+        $type = 'input';
+        $parts = explode(':', trim($prop));
 
-                if ($show[$idx]['mediatype'] == 'document' && in_array('DOCUMENT', $parts)) {
-                    $show_item = true;
-                }
+        if (in_array('MULTI', $parts)) {
+            $type = 'textarea';
+        }
 
-                if ($show[$idx]['mediatype'] == 'archive' && in_array('ARCHIVE', $parts)) {
-                    $show_item = true;
-                }
+        if (preg_match('@(AUDIO|VIDEO|DOCUMENT|IMAGE|ARCHIVE|BINARY)@i', $prop)) {
+            $show_item = false;
+            if ($media['mediatype'] == 'video' && in_array('VIDEO', $parts)) {
+                $show_item = true;
+            }
 
-                if ($show[$idx]['mediatype'] == 'binary' && in_array('BINARY', $parts)) {
-                    $show_item = true;
-                }
+            if ($media['mediatype'] == 'audio'  && in_array('AUDIO', $parts)) {
+                $show_item = true;
+            }
 
-                if (!$show_item) {
-                    continue;
-                }
+            if ($media['mediatype'] == 'image'  && in_array('IMAGE', $parts)) {
+                $show_item = true;
             }
 
-            if (!$is_edit) {
-                $type = 'readonly';
+            if ($media['mediatype'] == 'document' && in_array('DOCUMENT', $parts)) {
+                $show_item = true;
             }
-            $val =& serendipity_mediaTypeCast($parts[0], $props['base_property'][$parts[0]], true);
-
-            $propkey = htmlspecialchars($parts[0]) . $idx;
-
-            $show[$idx]['base_property'][$propkey] = array(
-                'label' => htmlspecialchars(defined('MEDIA_PROPERTY_' . strtoupper($parts[0])) ? constant('MEDIA_PROPERTY_' . strtoupper($parts[0])) : $parts[0]),
-                'type'  => $type,
-                'val'   => $val,
-                'title' => htmlspecialchars($parts[0])
-            );
-
-            if (empty($val)) {
-                switch($parts[0]) {
-                    case 'DATE':
-                        $show[$idx]['base_property'][$propkey]['val'] = serendipity_strftime(DATE_FORMAT_SHORT, serendipity_pickKey($show[$idx]['metadata'], 'DateCreated', $now));
-                        break;
-
-                    case 'RUN_LENGTH':
-                        $show[$idx]['base_property'][$propkey]['val'] = serendipity_pickKey($show[$idx]['metadata'], 'RunLength', '00:00:00.00');
-                        break;
-
-                    case 'DPI':
-                        $show[$idx]['base_property'][$propkey]['val'] = serendipity_pickKey($show[$idx]['metadata'], 'XResolution', 72);
-                        break;
-
-                    case 'COPYRIGHT':
-                        $show[$idx]['base_property'][$propkey]['val'] = serendipity_pickKey($show[$idx]['metadata'], 'Creator', $serendipity['serendipityUser']);
-                        break;
-
-                    case 'TITLE':
-                        $show[$idx]['base_property'][$propkey]['val'] = serendipity_pickKey($show[$idx]['metadata'], 'Title', $media['internal']['realname']);
-                        break;
-
-                    case 'COMMENT1':
-                        $show[$idx]['base_property'][$propkey]['val'] = serendipity_pickKey($show[$idx]['metadata'], 'Keywords', '');
-                        break;
-
-                    case 'COMMENT2':
-                        $show[$idx]['base_property'][$propkey]['val'] = serendipity_pickKey($show[$idx]['metadata'], 'PhotoLocation', '');
-                        break;
-
-                    default:
-                        serendipity_plugin_api('media_showproperties', $show[$idx], $propkey);
-                        break;
-                }
+
+            if ($media['mediatype'] == 'archive' && in_array('ARCHIVE', $parts)) {
+                $show_item = true;
+            }
+
+            if ($media['mediatype'] == 'binary' && in_array('BINARY', $parts)) {
+                $show_item = true;
+            }
+
+            if (!$show_item) {
+                continue;
             }
         }
 
+        if (!$is_edit) {
+            $type = 'readonly';
+        }
+        $val =& serendipity_mediaTypeCast($parts[0], $props['base_property'][$parts[0]], true);
+
+        $propkey = htmlspecialchars($parts[0]) . $idx;
+
+        $media['base_property'][$propkey] = array(
+            'label' => htmlspecialchars(defined('MEDIA_PROPERTY_' . strtoupper($parts[0])) ? constant('MEDIA_PROPERTY_' . strtoupper($parts[0])) : $parts[0]),
+            'type'  => $type,
+            'val'   => $val,
+            'title' => htmlspecialchars($parts[0])
+        );
+
+        if (empty($val)) {
+            switch($parts[0]) {
+                case 'DATE':
+                    $media['base_property'][$propkey]['val'] = serendipity_strftime(DATE_FORMAT_SHORT, serendipity_pickKey($media['metadata'], 'DateCreated', $now));
+                    break;
+
+                case 'RUN_LENGTH':
+                    $media['base_property'][$propkey]['val'] = serendipity_pickKey($media['metadata'], 'RunLength', '00:00:00.00');
+                    break;
+
+                case 'DPI':
+                    $media['base_property'][$propkey]['val'] = serendipity_pickKey($media['metadata'], 'XResolution', 72);
+                    break;
+
+                case 'COPYRIGHT':
+                    $media['base_property'][$propkey]['val'] = serendipity_pickKey($media['metadata'], 'Creator', $serendipity['serendipityUser']);
+                    break;
+
+                case 'TITLE':
+                    $media['base_property'][$propkey]['val'] = serendipity_pickKey($media['metadata'], 'Title', $media['internal']['realname']);
+                    break;
+
+                case 'COMMENT1':
+                    $media['base_property'][$propkey]['val'] = serendipity_pickKey($media['metadata'], 'Keywords', '');
+                    break;
+
+                case 'COMMENT2':
+                    $media['base_property'][$propkey]['val'] = serendipity_pickKey($media['metadata'], 'PhotoLocation', '');
+                    break;
+
+                default:
+                    serendipity_plugin_api::hook_event('media_showproperties', $media, $propkey);
+                    break;
+            }
+        }
+    }
+
+    if ($keywordsPerBlock > 0) {
         $rows = ceil(count($keywords) / $keywordsPerBlock);
         for($i = 0; $i < $rows; $i++) {
             for ($j = 0; $j < $keywordsPerBlock; $j++) {
                 $kidx = ($i*$keywordsPerBlock) + $j;
                 if (isset($keywords[$kidx])) {
-                    $show[$idx]['base_keywords'][$i][$j] = array(
+                    $media['base_keywords'][$i][$j] = array(
                         'name'      => htmlspecialchars($keywords[$kidx]),
                         'selected'  => isset($props['base_keyword'][$keywords[$kidx]]) ? true : false
                     );
                 } else {
-                    $show[$idx]['base_keywords'][$i][$j] = array();
+                    $media['base_keywords'][$i][$j] = array();
                 }
             }
         }
     }
-
-    // TODO: EXIF!
-    $smarty_vars = array(
-        'is_edit'           => $is_edit,
-        'editform_hidden'   => $editform_hidden,
-        'keywordsPerBlock'  => $keywordsPerBlock,
-        'keywords'          => $keywords,
-        'dprops'            => $dprops
-    );
-    return serendipity_showMedia(
-        $show,
-        $mirror,
-        $url,
-        false,
-        1,
-        false,
-        $smarty_vars);
 }
 
 /**
@@ -2181,7 +2219,7 @@ function serendipity_showPropertyForm(&$new_media, $keywordsPerBlock = 3, $is_ed
  */
 function serendipity_mediaTypeCast($key, $val, $invert = false) {
     if (stristr($key, 'date') !== FALSE) {
-        if ($invert && is_int($val)) {
+        if ($invert && is_numeric($val)) {
             return serendipity_strftime(DATE_FORMAT_SHORT, $val, false);
         } elseif ($invert === false) {
             $tmp = strtotime($val);
@@ -2214,6 +2252,51 @@ function serendipity_mediaTypeCast($key, $val, $invert = false) {
     return $val;
 }
 
+/**
+ * Inserts media properties
+ *
+ * @param   string  Property_group
+ * @return array    array('image_id') holding the last created thumbnail for immediate processing
+ *
+ */
+function serendipity_insertMediaProperty($property_group, $property_subgroup = '', $image_id, &$media, $use_cast = true) {
+    global $serendipity;
+
+    serendipity_db_query("DELETE FROM {$serendipity['dbPrefix']}mediaproperties
+                                WHERE mediaid = " . (int)$image_id . "
+                                  " . ($property_subgroup != 'ALL' ? "AND property_subgroup = '" . serendipity_db_escape_string($property_subgroup) . "'" : '') . "
+                                  AND property_group = '" . serendipity_db_escape_string($property_group) . "'");
+
+    if (is_array($media)) {
+        foreach($media AS $key => $val) {
+            if ($key == 'image_id') continue;
+
+            if (is_array($val)) {
+                $use_property_subgroup = $key;
+                $use_val = $val;
+            } else {
+                $use_property_subgroup = $property_subgroup;
+                $use_val = array($key => $val);
+            }
+
+            foreach($use_val AS $insert_key => $insert_val) {
+                if ($use_cast) {
+                    $insert_val = serendipity_mediaTypeCast($insert_key, $insert_val);
+                }
+                $q = sprintf("INSERT INTO {$serendipity['dbPrefix']}mediaproperties
+                                          (mediaid, property_group, property_subgroup, property, value)
+                                   VALUES (%d, '%s', '%s', '%s', '%s')",
+                             $image_id,
+                             serendipity_db_escape_string($property_group),
+                             serendipity_db_escape_string($useproperty_subgroup),
+                             serendipity_db_escape_string($insert_key),
+                             serendipity_db_escape_string($insert_val));
+                serendipity_db_query($q);
+            }
+        }
+    }
+}
+
 /**
  * Inserts the submitted properties of uploaded media items
  *
@@ -2230,58 +2313,22 @@ function serendipity_parsePropertyForm() {
     serendipity_checkPropertyAccess($serendipity['POST']['mediaProperties'], $serendipity['POST']['mediaKeywords'], 'write');
 
     foreach($serendipity['POST']['mediaProperties'] AS $id => $media) {
-        serendipity_db_query("DELETE FROM {$serendipity['dbPrefix']}mediaproperties
-                                    WHERE mediaid = " . (int)$media['image_id'] . "
-                                      AND property_subgroup = ''
-                                      AND property_group = 'base_property'");
-        foreach($media AS $key => $val) {
-            if ($key == 'image_id') continue;
-            $val = serendipity_mediaTypeCast($key, $val);
-            $q = sprintf("INSERT INTO {$serendipity['dbPrefix']}mediaproperties
-                                      (mediaid, property_group, property_subgroup, property, value)
-                               VALUES (%d, 'base_property', '', '%s', '%s')",
-                         $media['image_id'],
-                         serendipity_db_escape_string($key),
-                         serendipity_db_escape_string($val));
-            serendipity_db_query($q);
-        }
+        serendipity_insertMediaProperty('base_property', '', $media['image_id'], $media);
 
         $s9y_img = $media['internal'];
         $s9y_img['image_id'] = $media['image_id'];
         serendipity_prepareMedia($s9y_img);
         $s9y_img['metadata'] =& serendipity_getMetaData($s9y_img['realfile'], $s9y_img['header']);
-        serendipity_db_query("DELETE FROM {$serendipity['dbPrefix']}mediaproperties
-                                    WHERE mediaid = " . (int)$media['image_id'] . "
-                                          property_group = 'base_metadata'");
-        foreach($s9y_img['metadata'] AS $maingroup => $items) {
-            foreach($items AS $key => $val) {
-                $val = serendipity_mediaTypeCast($key, $val);
-                $q = sprintf("INSERT INTO {$serendipity['dbPrefix']}mediaproperties
-                                          (mediaid, property_group, property_subgroup, property, value)
-                                   VALUES (%d, 'base_metadata', '%s', '%s', '%s')",
-                             $media['image_id'],
-                             $maingroup,
-                             serendipity_db_escape_string($key),
-                             serendipity_db_escape_string($val));
-                serendipity_db_query($q);
-            }
-        }
+        serendipity_insertMediaProperty('base_metadata', 'ALL', $media['image_id'], $s9y_img['metadata']);
+        $s9y_img['hidden'] = array(
+            'author'   => $serendipity['serendipityUser'],
+            'authorid' => $serendipity['authorid']
+        );
+        serendipity_insertMediaProperty('base_hidden', '', $media['image_id'], $s9y_img['hidden']);
     }
 
     foreach($serendipity['POST']['mediaKeywords'] AS $id => $keywords) {
-        serendipity_db_query("DELETE FROM {$serendipity['dbPrefix']}mediaproperties
-                                    WHERE mediaid = " . (int)$serendipity['POST']['mediaProperties'][$id]['image_id'] . "
-                                      AND property_subgroup = ''
-                                      AND property_group = 'base_keyword'");
-
-        foreach($keywords AS $keyword => $checked) {
-            $q = sprintf("INSERT INTO {$serendipity['dbPrefix']}mediaproperties
-                                      (mediaid, property_group, property_subgroup, property, value)
-                               VALUES (%d, 'base_keyword', '', '%s', '1')",
-                         $serendipity['POST']['mediaProperties'][$id]['image_id'],
-                         serendipity_db_escape_string($keyword));
-            serendipity_db_query($q);
-        }
+        serendipity_insertMediaProperty('base_keyword', '', $serendipity['POST']['mediaProperties'][$id]['image_id'], $keywords);
     }
 
     $array = array(
index 736de7a1d0951968031fd9b2c60f9df4ad81f92a..4b329a9c8c03d27b24cc9c2709df839c2c9f9478 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Въведете максималната височина в пиксели на изображенията, които ще се качват.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Грешка: Не можете да качвате изображения, по-големи от %s x %s пиксела.');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 4abd7ac52729bd9c599359db45eea59cc4f22dc5..d72e55398d6e75e4ef6e3d509e7e85c94f2082cb 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_cn.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_cn.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 /* vim: set sts=4 ts=4 expandtab : */
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index f41dffbcfeefd89a609a21bb873e378d9f3d1dd3..742f5609e9aaf608965771af3d1b2ec8f96442a1 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_cs.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_cs.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) 2005 Josef Klimosz <ok2wo@centrum.cz>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 6ad33f4ac6de0aaf9e2f3e66be3539aa3ef75ff0..ff384707cc9d0b37e666dd98275ebce43eb1aebe 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_cz.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_cz.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) 2004 Josef Klimosz <ok2wo@centrum.cz>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index df926111d32e9103060b9d94f0043945fe5de1d9..6626c655a9f268086fc6be29c91edc74a287f529 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_da.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_da.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) by Tom Sommer, <ts@dreamcoder.dk>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index b81fad5606f16817bfd1f79f42b15a7e07a02c1b..88d1375300605869af3bf6ed3c6bc835be5bb81f 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_de.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_de.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) Jannis Hermanns, Garvin Hicking and others
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 803b8a673f3992cf652a28864a9b7dfb45ce5c24..09e9f315d1e765fcac621e1d207ee371ce0eab2d 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_en.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_en.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 /* vim: set sts=4 ts=4 expandtab : */
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index d87719c459e2baed8e54f6eef85ad2f9c3cc818b..9983b3a44bc2001c7bf900e3766928e9413f151b 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_es.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_es.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) by Luis Cervantes <LuisCervantes@ono.com>,
@@ -875,3 +875,8 @@ Melvin TODO [20060128]: What spanish word do we use for "referrers" ??
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 864c7a1ead1bdcca62dcaaa211cec59534e77519..93039e08f84e3faca6f4ac14558127fdfed14925 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_fa.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_fa.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved. See LICENSE file for licensing details
 # this translation, translated by Omid Mottaghi <http://oxygenws.com>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 88bdc9cdc7e792ba4c1f7f608f27a1403f4a1d9f..1e3c1f4c528e054dcbd04c297c8819d2a6bd95c3 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_fi.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_fi.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation by Mauri Sahlberg <mos@iki.fi>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index e3321996f18e9b825d2eb3925add03120988f80f..6bc7e2ac01fa17aed3ef9ce12f76011997d1121b 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_fr.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_fr.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation by Sebastian Mordziol <argh@php-tools.net>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 8aa66fb0f57437a10b34c65b09f40540356be3ce..568506f5957b6481958d9861a7014a3200238f86 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index eaefa1f52f0a471bec4cbefb97ccaaffe78f703a..ae391aa0a721ae0592b283a4bc5770143e438e91 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_is.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_is.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation by Örn Arnarson <orn@arnarson.net>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index e18bd4f210193b0bca83bb8fb4712e085b2caad5..b9ec78d422173d81cb765c2098f669b618950c4f 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 6e1e8864af48b681032db1760b17e5c3c4a665dd..fce1ca507395caa0377b68096290640515124165 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_ja.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_ja.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) Tadashi Jokagi <elf2000@users.sourceforge.net>, 2004-2005.
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 0c0c9db7c8ae058011c4f489eec6fb42d4d8d2e9..2c9769a7ef783ebbe67c4fcca9e1f6fb92b3e0a8 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_ko.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_ko.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translated by: Wesley Hwang-Chung <wesley96@gmail.com>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index cede35599756e0f239805678c0a1481621acae49..4dd82d241d9a5e4d04938d40b39421b6fd4b6e70 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_nl.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_nl.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) by Christiaan Heerze <webmaster@heimp.nl>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 5b4384908d36f412bf17922289d6fbe522a75f52..b6727a584dab1ed228c5619968728c6aa99c59d4 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_no.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_no.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) by Jo Christian Oterhals <oterhals@gmail.com>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 6eae8ee8b4b5313e0f91b126098aa4ad4ad781de..7476d00c41597bb0c8aa94c82467a7b5180fc48e 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_pt.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_pt.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation (c) by Agner Olson <agner@agner.net>
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 4387e503072ea4d59073e1ebe33f48ee587225e0..c850e976f0d47cc3654e82a0f79c54a56527c38b 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 2ba5c1fd2245538c1a24b228dd0d6f53969faffb..ef03ca54c3913912eb569f93f61ce3d92e0d5b56 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 3f575d7d83f377704b1082fb61cca5ec2b281579..463ba30388b09da279f0fc965604b9fc27bfd385 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_ru.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_ru.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translation by Nightly <nightly@reys.net>
@@ -861,3 +861,8 @@ $i18n_filename_to   = array('_', 'a', 'A', 'b', 'B', 'v', 'V', 'g', 'G', 'd', 'D
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index fd0baffc2cf0e99d83ad93aafcbc5a1b6561ce05..cf4d04065669a0178e0c92f10de8d839b9dbf8f7 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index b3bc7fc1347b167a54912cf0a40fcb20fcaee37c..21fb2603efcb3f66e5b884404401440d26801524 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 5e544094c76dc26e0368fb4d69b56c9fbb6d35b6..17b40112f45086e45cb0a95cd47946765d096519 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_tn.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_tn.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translated by CapriSkye <admin@capriskye.com>
@@ -860,3 +860,8 @@ $i18n_unknown = 'tw';
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 1a71b1a55b5ad3a19873e10d8bb404b60a67e214..34d6298b34b112260d799f068719ace79884dd92 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index d8b75dcb8c418c01074ec1bf4511b28ca92190c9..b84ea92e5cfd45af063e0d78522d9248be17d9ad 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_tw.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_tw.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 # Translated by CapriSkye <admin@capriskye.com>
@@ -860,3 +860,8 @@ $i18n_unknown = 'tw';
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 9db85d3829cf5db5c41cfe1aa2880b906549e709..e21809b82a162160a4ccaef3aebd5377f367d7e3 100644 (file)
@@ -1,4 +1,4 @@
-<?php # $Id: serendipity_lang_zh.inc.php 1119 2006-04-19 08:32:48Z garvinhicking $
+<?php # $Id: serendipity_lang_zh.inc.php 1122 2006-04-19 11:07:47Z garvinhicking $
 # Copyright (c) 2003-2005, Jannis Hermanns (on behalf the Serendipity Developer Team)
 # All rights reserved.  See LICENSE file for licensing details
 /* vim: set sts=4 ts=4 expandtab : */
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 33dacb4632a49b0336b9b5c2c924643d33846285..adc20ba0386f6166f186d58b55530ab2e03878de 100644 (file)
@@ -1,9 +1,5 @@
-@define('MEDIA_UPLOAD_SIZE', 'Max. file upload size');
-@define('MEDIA_UPLOAD_SIZE_DESC', 'Enter the maximum filesize for uploaded files in bytes. This setting can be overruled by server-side settings in PHP.ini: upload_max_filesize, post_max_size, max_input_time all take precedence over this option. An empty string means to only use the server-side limits.');
-@define('MEDIA_UPLOAD_SIZEERROR', 'Error: You cannot upload files larger than %s bytes!');
-@define('MEDIA_UPLOAD_MAXWIDTH', 'Max. width of image files for upload');
-@define('MEDIA_UPLOAD_MAXWIDTH_DESC', 'Enter the maximum image width in pixels for uploaded images.');
-@define('MEDIA_UPLOAD_MAXHEIGHT', 'Max. height of image files for upload');
-@define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
-@define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
 
index 352b5ec8299a7458be1d4f1528af1c7a86a576a5..4b87c0678487469b5cfc34dabf09a27075129f94 100644 (file)
@@ -133,3 +133,8 @@ foreach($const['missing'] AS $file => $constants) {
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index f2e47f303765443630ac9f877837c46afddff642..497867ecad6b87aadf86b33c87568435eb095f7a 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Âúâåäåòå ìàêñèìàëíàòà âèñî÷èíà â ïèêñåëè íà èçîáðàæåíèÿòà, êîèòî ùå ñå êà÷âàò.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Ãðåøêà: Íå ìîæåòå äà êà÷âàòå èçîáðàæåíèÿ, ïî-ãîëåìè îò %s x %s ïèêñåëà.');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 2ea0d7da1d41d80dcdfb7af2398e7bc4a5dbd444..881470823c0bdb5a1c608ce3781cd3103ddeb1d0 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index ecc2e41a75f85c86a063eba30e39cf88e98ae4a5..a7fc7e32b289159c17827d7f97af024795264fc3 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 3f609f80447183231939e5ebe411092a3792e3c2..fb09c233d7544d99d36da172211ddbe64d722cf0 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 8b0f8bb16913760825db8acbbe33aef56171250e..17698498e822d4203b328b41ff476c05ac3768fe 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 19321c82ad86ce55a608abb702628d67fac20d24..9949345334ffc126ac8f24a9adba59d3ea7a54d5 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index a40ae10235c899a08aa39e85d770913dc72f598c..35ba0bb9480d1cf0e9058e23c3ee28c94cadb06e 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index d072c020a04d34504946173c5ba7fd9f00f8dd5b..cb49967b9b700dfc9711e463175a5f40ac0b941b 100644 (file)
@@ -875,3 +875,8 @@ Melvin TODO [20060128]: What spanish word do we use for "referrers" ??
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index f48d01a3d958092f60d78d0be3ff8ff4b7615806..b2e68bec72c366c481a3955c208f28f5072107dc 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index dc8be4305d8b5f48b19058d99098cd12582bb66c..1e57a0eae3a9134a8bbd5dc5a156d1eaaccc5a52 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index df4d440a553c9fe27f150142445f0124161e27e3..c86f2912bcc162d7b1f3030756e950a604f4751b 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index ddc499e98be6a5f76df0c6b7819397e31e3b2695..6b3ddf03b7629939faf5dd7e7d5616c61ecba563 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 47b2e62be1dcd1d92c054968769032e9ea6827d7..e02a3a28554696be5ea6e45d8060afc1335ff23b 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 27b8e1db1959332c493d7b6ea32ddd75cf9b68a3..aa8e1bad8ed37fe9c7afe35b2f8805566ccd82ba 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 3cab0b1d6ab99dec69b273ee2c2a59bbd45fb7da..7d889a56f50649cfd2b9b6bc534e129fda962b72 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 6df4f34e559fdf08034b29e60317b52353b1adff..300ad4a0c22ac4af81dbd1331c89d0637a1af732 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 80e33ab3c41b57d62630cbb1325fe9fbdf2db686..8e5898299f0d2d5e6814060db882ac6cc7003ae6 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index f175b95e519595e9dc0c64ed73cc07ccbbe4d261..79fd0c5475d93b392f1c20cab0809f528607e3bf 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 2f134033487178821212a0f6bc2cba0e01f57e05..ab4961b37fdf8d6618bd6037f620bf315590a2dd 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 94a8784aacfebdbc43e64e5fe406e1f50edc824f..b6558400c644b2cda7f4e53bb96c1fea03b95bcb 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 2ba5c1fd2245538c1a24b228dd0d6f53969faffb..ef03ca54c3913912eb569f93f61ce3d92e0d5b56 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 59574f1687ffee7c23b8faf3321012af91e06471..0ded5b801f2c47470c9d393b7ef12860d1b3bb1b 100644 (file)
@@ -861,3 +861,8 @@ $i18n_filename_to   = array('_', 'a', 'A', 'b', 'B', 'v', 'V', 'g', 'G', 'd', 'D
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 056086c5df3bd89dc39f3092c0009a1ba0834a0c..ca67be787e9af9dc75277f809295156f96e164bd 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index b3bc7fc1347b167a54912cf0a40fcb20fcaee37c..21fb2603efcb3f66e5b884404401440d26801524 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 702be332cda0ed958cdc9a86d5eabb3ddb1e9651..224cb66843553aec3f24e71d02d82bf51c1ec5e6 100644 (file)
@@ -860,3 +860,8 @@ $i18n_unknown = 'tw';
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 1a71b1a55b5ad3a19873e10d8bb404b60a67e214..34d6298b34b112260d799f068719ace79884dd92 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 61f9a35b642e14a291953f0aed5bfb1b81a57e03..7ed95cb6d4a5f0820375963f5d618165d5b7b6a5 100644 (file)
@@ -860,3 +860,8 @@ $i18n_unknown = 'tw';
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index 115b751f218cd5ac275236601bbd015fa0dc4ae2..46248dea729c3c7b4f57c487da25428778d378a9 100644 (file)
 @define('MEDIA_UPLOAD_MAXHEIGHT_DESC', 'Enter the maximum image height in pixels for uploaded images.');
 @define('MEDIA_UPLOAD_DIMERROR', 'Error: You cannot upload image files larger than %s x %s pixels!');
 
+@define('MEDIA_TARGET', 'Target for this link');
+@define('MEDIA_TARGET_JS', 'Popup window (via JavaScript, adaptive size)');
+@define('MEDIA_ENTRY', 'Isolated Entry');
+@define('MEDIA_TARGET_BLANK', 'Popup window (via target=_blank)');
+
index b74949b2fe288b25ffb34e377306c73647f2676a..1eb602fe760e82265effcaa5fcdba5c873b45380 100644 (file)
@@ -10,7 +10,7 @@ if (IN_serendipity !== true) {
 
 header('Content-Type: text/html; charset=' . LANG_CHARSET);
 
-if ($_SESSION['serendipityAuthedUser'] !== true)  {
+if ($_SESSION['serendipityAuthedUser'] !== true && $serendipity['GET']['step'] != 'showItem')  {
     die(HAVE_TO_BE_LOGGED_ON);
 }
 
@@ -37,6 +37,7 @@ if (empty($serendipity['GET']['step']) && $serendipity['GET']['page'] < 1) {
     return;
 }
 
+$showFile = 'admin/media_choose.tpl';
 $body_id = 'serendipityAdminBodyImageSelector';
 if ($serendipity['GET']['step'] === 'tree') {
     $body_id = 'serendipityAdminBodyImageSelectorTree';
@@ -47,8 +48,10 @@ $media = array(
     'only_path' => $serendipity['GET']['only_path'],
     'css'       => serendipity_rewriteURL('serendipity_admin.css'),
     'css_tree'  => serendipity_getTemplateFile('treeview/tree.css'),
+    'css_front' => serendipity_rewriteURL('serendipity.css'),
     'token_url' => serendipity_setFormToken('url'),
-    'imgID'     => (int)$serendipity['GET']['image']
+    'imgID'     => (int)$serendipity['GET']['image'],
+    'from'      => $serendipity['GET']['from']
 );
 
 switch ($serendipity['GET']['step']) {
@@ -111,7 +114,7 @@ switch ($serendipity['GET']['step']) {
         serendipity_plugin_api::hook_event('media_getproperties_cached', $media['file']['props']['base_metadata'], $media['file']['realfile']);
 
         if ($file['is_image']) {
-            $file['finishJSFunction'] = 'serendipity_imageSelector_done(\'' . htmlspecialchars($serendipity['GET']['textarea']) . '\')';
+            $file['finishJSFunction'] = $file['origfinishJSFunction'] = 'serendipity_imageSelector_done(\'' . htmlspecialchars($serendipity['GET']['textarea']) . '\')';
 
             if (!empty($serendipity['GET']['filename_only']) && $serendipity['GET']['filename_only'] !== 'true') {
                 $file['fast_select'] = true;
@@ -161,6 +164,31 @@ switch ($serendipity['GET']['step']) {
         $media['paths'] =& $paths;
         break;
 
+    case 'showItem':
+        $media['case'] = 'showitem';
+        $file          = serendipity_fetchImageFromDatabase((int)$serendipity['GET']['image']);
+        $media['file'] = &$file;
+        $keywords = $dprops = '';
+
+        if (!is_array($file)) {
+            $media['perm_denied'] = true;
+            break;
+        }
+
+        serendipity_prepareMedia($file);
+
+        $media['file']['props'] =& serendipity_fetchMediaProperties((int)$serendipity['GET']['image']);
+        serendipity_plugin_api::hook_event('media_getproperties_cached', $media['file']['props']['base_metadata'], $media['file']['realfile']);
+
+        serendipity_parseMediaProperties($keywords, $dprops, $media['file'], $media['file']['props'], 0, false);
+        serendipity_plugin_api::hook_event('frontend_media_showitem', $media);
+        if ($media['perm_denied']) {
+            unset($media['file']);
+            unset($file);
+        }
+        $showFile = 'admin/media_showitem.tpl';
+        break;
+
     case 'default':
     default:
         if (!empty($serendipity['GET']['adminAction']) && $serendipity['GET']['adminModule'] == 'images' && $serendipity['GET']['adminAction'] != 'default') {
@@ -205,6 +233,6 @@ switch ($serendipity['GET']['step']) {
 
 $media = array_merge($serendipity['GET'], $media);
 $serendipity['smarty']->assign('media', $media);
-$serendipity['smarty']->display(serendipity_getTemplateFile('admin/media_choose.tpl', 'serendipityPath'));
+$serendipity['smarty']->display(serendipity_getTemplateFile($showFile, 'serendipityPath'));
 
 /* vim: set sts=4 ts=4 expandtab : */
\ No newline at end of file
index d8c6c72b29f59746cb12e04e545edc2027ef1e42..0ceaae0bbdf061d20b0cf205b3f37ea49e807839 100644 (file)
@@ -229,6 +229,10 @@ function serendipity_imageSelector_done(textarea)
     if (f['imgID']) {
         imgID = f['imgID'].value;
     }
+    baseURL = '';
+    if (f['baseURL']) {
+        baseURL = f['baseURL'].value;
+    }
 
     floating = 'center';
     if (f['serendipity[align]'][0].checked == true) {
@@ -242,7 +246,32 @@ function serendipity_imageSelector_done(textarea)
     }
 
     if (f['serendipity[isLink]'][1].checked == true) {
-        insert = "<a class='serendipity_image_link' href='" + f['serendipity[url]'].value + "'>" + img + "</a>";
+        if (f['serendipity[target]'].selectedIndex) {
+            targetval = f['serendipity[target]'].options[f['serendipity[target]'].selectedIndex].value;
+        } else {
+            targetval = '';
+        }
+
+        prepend   = '';
+        ilink     = f['serendipity[url]'].value;
+        if (!targetval || targetval == 'none') {
+            itarget = '';
+        } else if (targetval == 'js') {
+            itarget = ' onclick="F1 = window.open(\'' + f['serendipity[url]'].value + '\',\'Zoom\',\''
+                    + 'height=' + (parseInt(f['imgHeight'].value) + 15) + ','
+                    + 'width='  + (parseInt(f['imgWidth'].value)  + 15) + ','
+                    + 'top='    + (screen.height - f['imgHeight'].value) /2 + ','
+                    + 'left='   + (screen.width  - f['imgWidth'].value)  /2 + ','
+                    + 'toolbar=no,menubar=no,location=no,resize=1,resizable=1,scrollbars=yes\'); return false;"';
+        } else if (targetval == '_blank') {
+            itarget = ' target="_blank"';
+        } else if (targetval == 'plugin') {
+            itarget = ' id="s9yisphref' + imgID + '" onclick="javascript:this.href = this.href + \'&amp;serendipity[from]=\' + self.location.href;"';
+            prepend = '<a title="' + ilink + '" id="s9yisp' + imgID + '"></a>';
+            ilink   = baseURL + 'serendipity_admin_image_selector.php?serendipity[step]=showItem&amp;serendipity[image]=' + imgID;
+        }
+
+        insert = prepend + "<a class='serendipity_image_link' href='" + ilink + "'" + itarget + ">" + img + "</a>";
     } else {
         insert = img;
     }
index 0c74ecc4fcba1d866c1c2000403914acfd22c026..24e4fbd521d746084a4aae97551d592a3e0231af 100644 (file)
                     <input type="hidden" name="imgWidth"  value="{$media.file.dimensions_width}" />
                     <input type="hidden" name="imgHeight" value="{$media.file.dimensions_height}" />
                     <input type="hidden" name="imgID" value="{$media.imgID}" />
+                    <input type="hidden" name="baseURL" value="{$serendipityBaseURL}" />
+                    <input type="hidden" name="indexFile" value="{$serendipityIndexFile}" />
                     <input type="hidden" name="imgName"   value="{$media.file.full_file}" />
                     <input type="hidden" name="thumbName" value="{$media.file.show_thumb}" />
                     <input type="hidden" name="hotlink" value="{$media.file.hotlink}" />
                         {serendipity_hookPlugin hookAll=true hook='frontend_image_selector_link_url' eventData=$media.file.links}
                         <input type="text"  name="serendipity[url]" size="30" value="{$media.file.links.imagelinkurl}" /><br />
                     {/if}
-                    {serendipity_hookPlugin hookAll=true hook='frontend_image_selector_imagelink' eventData=$media.file}
+
+                    <label id="select_image_target">{$CONST.MEDIA_TARGET}</label>
+                        <select name="serendipity[target]" id="select_image_target">
+                            <option value="none"   {'target'|@ifRemember:'none':false:'selected'}>{$CONST.NONE}</option>
+                            <option value="js"     {'target'|@ifRemember:'js':false:'selected'}>{$CONST.MEDIA_TARGET_JS}</option>
+                            <option value="plugin" {'target'|@ifRemember:'plugin':false:'selected'}>{$CONST.MEDIA_ENTRY}</option>
+                            <option value="_blank" {'target'|@ifRemember:'_blank':false:'selected'}>{$CONST.MEDIA_TARGET_BLANK}</option>
+                        </select>
+                    <br />
+
+                    {serendipity_hookPlugin hookAll=true hook='frontend_image_selector_imagelink2' eventData=$media.file}
                     <br />
 
                     <b>{$CONST.COMMENT}:</b>
                     {serendipity_hookPlugin hookAll=true hook='frontend_image_selector_more' eventData=$media.file}
 
                     <input type="button" value="{$CONST.BACK}" onclick="history.go(-1);" />
-                    <input type="button" value="{$CONST.DONE}" onclick="rememberOptions(); {$media.file.finishJSFunction}" />
+                    <input type="button" value="{$CONST.DONE}" onclick="rememberOptions(); {$media.file.origfinishJSFunction}" />
                     {serendipity_hookPlugin hookAll=true hook='frontend_image_selector_submit' eventData=$media.file}
                 {/if}
             </div>
diff --git a/templates/default/admin/media_showitem.tpl b/templates/default/admin/media_showitem.tpl
new file mode 100644 (file)
index 0000000..606d952
--- /dev/null
@@ -0,0 +1,76 @@
+<html>
+    <head>
+        <title>{$media.file.props.base_property.TITLE|@default:$media.file.realname}</title>
+        <meta http-equiv="Content-Type" content="text/html; charset={$CONST.LANG_CHARSET}" />
+        <link rel="stylesheet" type="text/css" href="{$media.css}" />
+        <link rel="stylesheet" type="text/css" href="{$media.css_front}" />
+    </head>
+
+<body id="{$media.body_id}">
+    {if $perm_denied}
+        {$CONST.PERM_DENIED}
+    {else}
+    <div class="serendipity_Entry_Date">
+        <h3 class="serendipity_date">{$media.file.realname}</h3>
+        <h4 class="serendipity_title"><a href="#">{$media.file.props.base_property.TITLE|@default:''}</a></h4>
+
+        <div class="serendipity_entry">
+            <div class="serendipity_entry_body">
+                <div class="serendipity_center">
+                    {if $media.file.is_image}
+                        <img src="{$media.file.full_file}" />
+                    {else}
+                        <a href="{$media.file.full_file}">{$media.file.realname} ({$media.file.displaymime})</a>
+                    {/if}
+                    <br /><a href="{$media.from|@escape}" title="{$CONST.BACK_TO_BLOG}">{$CONST.BACK_TO_BLOG}</a>
+                </div>
+                <br />
+
+                {if $media.file.base_property}
+                <h3>{$CONST.MEDIA_PROP}</h3>
+                <div>
+                <dl>
+                {foreach from=$media.file.base_property key="prop_fieldname" item="prop_content"}
+                {if $prop_content.val}
+                    <dt>{$prop_content.label}</dt>
+                    <dd>{$prop_content.val|@escape}</dd>
+                {/if}
+                {/foreach}
+                </dl>
+                </div>
+                {/if}
+
+                {if $media.file.props.base_keyword}
+                <h3>{$CONST.MEDIA_KEYWORDS}</h3>
+                <div>
+                {foreach from=$media.file.props.base_keyword key="prop_fieldname" item="prop_content"}
+                    {$prop_fieldname|@escape}&nbsp;
+                {/foreach}
+                    <p></p>
+                </div>
+                {/if}
+
+                {if $media.file.props.base_metadata}
+                <h3>EXIF/IPTC/XMP</h3>
+                <div>
+                <dl>
+                {foreach from=$media.file.props.base_metadata key="meta_type" item="meta_data"}
+                    <dt><strong>{$meta_type}</strong></dt>
+                    <dd><table>
+                    {foreach from=$meta_data key="meta_name" item="meta_value"}
+                        <tr>
+                            <td valign="top"><em>{$meta_name}</em></th>
+                            <td>{if is_array($meta_value)}<pre>{$meta_value|@print_r}</pre>{else}{$meta_value|@formatTime:DATE_FORMAT_SHORT:false:$meta_name}{/if}</td>
+                        </tr>
+                    {/foreach}
+                    </table></dd>
+                {/foreach}
+                </dl>
+                </div>
+                {/if}
+            </div>
+        </div>
+    </div>
+    {/if}
+</body>
+</html>