Changeset 21631 for extensions/AddInfo


Ignore:
Timestamp:
Mar 17, 2013, 1:08:24 PM (12 years ago)
Author:
ddtddt
Message:

[extensions] - AddInfo - change to 2.5 - chose emplacement imfo

Location:
extensions/AddInfo
Files:
22 edited

Legend:

Unmodified
Added
Removed
  • extensions/AddInfo/admin/admin.php

    r9405 r21631  
    2323               l10n('addinfo_explication'),
    2424               $my_base_url.'&tab=explication');
     25$tabsheet->add('gestion',
     26               l10n('Configuration'),
     27               $my_base_url.'&tab=gestion');
    2528$tabsheet->select($page['tab']);
    2629$tabsheet->assign();
     
    3942        break;
    4043       
     44  case 'gestion':
     45
     46  global $conf;
     47 
     48    $selected = $conf['AddInfo'];
     49        $options['Author'] = l10n('Author');
     50        $options['datecreate'] = l10n('Created on');
     51        $options['datepost'] = l10n('Posted on');
     52        $options['Dimensions'] = l10n('Dimensions');
     53        $options['File'] = l10n('File');
     54        $options['Filesize'] = l10n('Filesize');
     55        $options['Tags'] = l10n('tags');
     56        $options['Categories'] = l10n('Albums');
     57        $options['Visits'] = l10n('Visits');
     58        $options['Average'] = l10n('Rating score');
     59
     60       
     61
     62  $template->assign(
     63    'gestionA',
     64    array(
     65      'OPTIONS' => $options,
     66      'SELECTED' => $selected
     67      ));
     68   
     69
     70if (isset($_POST['infoaddinfo']))
     71        {
     72conf_update_param('AddInfo', $_POST['infoaddinfo']);
     73$template->delete_compiled_templates();
     74array_push($page['infos'], l10n('Your configuration settings are saved'));
     75
     76  $selected = $_POST['infoaddinfo'];
     77  $template->assign(
     78    'gestionA',
     79    array(
     80      'OPTIONS' => $options,
     81      'SELECTED' => $selected
     82      ));
     83        }
     84  break;
     85       
    4186}
    4287
  • extensions/AddInfo/admin/admin.tpl

    r9405 r21631  
    1313        </div>
    1414{/if}
     15{if isset ($gestionA)}
     16        <div>
     17                <form method="post" >
     18                        <fieldset>
     19                                <legend>{'Add information before'|@translate}</legend>
     20                {html_options name="infoaddinfo" options=$gestionA.OPTIONS selected=$gestionA.SELECTED}
     21                                <br>   
     22                                <br>
     23                                        <div style="text-align:center;">
     24                                        <input class="submit" name="submitpab" type="submit" value="{'Save Settings'|@translate}">
     25                                        </div>
     26                        </fieldset>
     27                </form>
     28        </div>
     29{/if}
  • extensions/AddInfo/initpicture.php

    r21629 r21631  
    1212function adddinfoIT($content, &$smarty)
    1313 {
    14   $search = '#<div id="datepost" class="imageInfo">#';
     14 
     15  global $conf;
     16 
     17  $search = '#<div id="'.$conf['AddInfo'].'" class="imageInfo">#';
    1518 
    1619  $replacement = '
  • extensions/AddInfo/language/ca_ES/plugin.lang.php

    r15369 r21631  
    3434$lang['addinfo_h2'] = 'Gestió de la informació addicional a la secció Imatges';
    3535$lang['addinfo_insing'] = 'inserir els valors a la base de dades';
     36$lang['Add information before'] = 'Abans afegiu informació';
    3637?>
  • extensions/AddInfo/language/da_DK/plugin.lang.php

    r18122 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'Indsæt værdierne i databasen';
     36$lang['Add information before'] = 'Tilføj oplysninger før';
    3637?>
  • extensions/AddInfo/language/de_DE/plugin.lang.php

    r9405 r21631  
    1515$lang[\'addinfo_info3\'] = \'Gewünschter Name für INFO3\'; <br>
    1616';
     17$lang['Add information before'] = 'Information davor hinzufügen';
    1718
    1819//onglet addinfo et admin info
  • extensions/AddInfo/language/el_GR/plugin.lang.php

    r15726 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'τοποθετήστε τις τιμές στη βάση δεδομένων';
     36$lang['Add information before'] = 'Προσθήκη πληροφοριών πριν';
    3637?>
  • extensions/AddInfo/language/en_UK/plugin.lang.php

    r9405 r21631  
    2121$lang['addinfo_info3'] = 'INFO3';
    2222
     23$lang['Add information before'] = 'Add information before';
     24
    2325
    2426?>
  • extensions/AddInfo/language/es_ES/plugin.lang.php

    r15823 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'insertar los valores en la base de datos';
     36$lang['Add information before'] = 'Agregar información antes';
    3637?>
  • extensions/AddInfo/language/fr_FR/plugin.lang.php

    r9405 r21631  
    2121$lang['addinfo_info3'] = 'INFO3';
    2222
    23 
     23$lang['Add information before'] = 'Ajouter l\'information avant';
    2424?>
  • extensions/AddInfo/language/it_IT/plugin.lang.php

    r10916 r21631  
    2020$lang['addinfo_info2'] = 'INFO2';
    2121$lang['addinfo_info3'] = 'INFO3';
     22$lang['Add information before'] = 'Aggiungi informazioni prima  ';
    2223
    2324
  • extensions/AddInfo/language/lv_LV/plugin.lang.php

    r9405 r21631  
    2020$lang['addinfo_info2'] = 'INFO2';
    2121$lang['addinfo_info3'] = 'INFO3';
    22 
     22$lang['Add information before'] = 'Pievienojiet informāciju pirms';
    2323
    2424?>
  • extensions/AddInfo/language/nb_NO/plugin.lang.php

    r9405 r21631  
    11<?php
    2 //ADMIN
    32$lang['addinfo_h2'] = 'Behandling av tilleggsinformasjon på bilde side';
    4 
    53$lang['addinfo_complete'] = 'Tilleggsinformasjon - Pluggin Legg til Info';
    64$lang['addinfo_insing'] = 'sett tinn vardiene i databasen';
    7 
    8 //onglet explication
    95$lang['addinfo_explication'] = 'Presentasjon';
    106$lang['addinfo_explication_help'] = 'Denne plugginen er et eksempel på hvordan man legger til ekstra informasjon på bilder, For å kunne bruke det, bør du tilpasse den';
     
    139$lang[\'addinfo_info1\'] = \'navn du vil ha for infos1\'; <br>
    1410$lang[\'addinfo_info2\'] = \'navn du vil ha for infos2\'; <br>
    15 $lang[\'addinfo_info3\'] = \'navn du vil ha for infos3\'; <br>
    16 ';
    17 
    18 //onglet addinfo et admin info
     11$lang[\'addinfo_info3\'] = \'navn du vil ha for infos3\'; <br>';
    1912$lang['addinfo_info1'] = 'INFO1';
    2013$lang['addinfo_info2'] = 'INFO2';
    2114$lang['addinfo_info3'] = 'INFO3';
    22 
    23 
     15$lang['Add information before'] = 'Legg til informasjon før';
    2416?>
  • extensions/AddInfo/language/nl_NL/plugin.lang.php

    r20111 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'Plaats de waarden in de database';
     36$lang['Add information before'] = 'Eerst de informatie invoeren';
    3637?>
  • extensions/AddInfo/language/pl_PL/plugin.lang.php

    r18230 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'dodaj wartości do bazy danych';
     36$lang['Add information before'] = 'Dodaj informację przed';
    3637?>
  • extensions/AddInfo/language/pt_PT/plugin.lang.php

    r16239 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'Inscrever os valores na base';
     36$lang['Add information before'] = 'Adicionar informação antes';
    3637?>
  • extensions/AddInfo/language/ru_RU/plugin.lang.php

    r15187 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'вставить значения в базу данных';
     36$lang['Add information before'] = 'Сначала добавьте информацию';
    3637?>
  • extensions/AddInfo/language/sk_SK/plugin.lang.php

    r9451 r21631  
    11<?php
    2 //ADMIN
    32$lang['addinfo_h2'] = 'Riadenie ďalšej informácie na stránke fotografií';
    4 
    53$lang['addinfo_complete'] = 'Ďalšia informácia - Doplnok Pridanie informácie';
    64$lang['addinfo_insing'] = 'vloženie hodnoty do databázy';
    7 
    8 //onglet explication
    95$lang['addinfo_explication'] = 'Prezentácia';
    106$lang['addinfo_explication_help'] = 'Tento doplnok je príklad pridávania informácií do fotografií, jeho použitie môžete prispôsobovať';
     
    139$lang[\'addinfo_info1\'] = \'názov, ktorý chcete pre infos1\'; <br>
    1410$lang[\'addinfo_info2\'] = \'názov, ktorý chcete pre infos2\'; <br>
    15 $lang[\'addinfo_info3\'] = \'názov, ktorý chcete pre infos3\'; <br>
    16 ';
    17 
    18 //onglet addinfo et admin info
     11$lang[\'addinfo_info3\'] = \'názov, ktorý chcete pre infos3\'; <br>';
    1912$lang['addinfo_info1'] = 'INFO1';
    2013$lang['addinfo_info2'] = 'INFO2';
    2114$lang['addinfo_info3'] = 'INFO3';
    22 
     15$lang['Add information before'] = 'Pridať informáciu pred';
    2316
    2417?>
  • extensions/AddInfo/language/tr_TR/plugin.lang.php

    r17943 r21631  
    3434$lang['addinfo_info3'] = 'BİLGİ3';
    3535$lang['addinfo_insing'] = 'Veri tabanındaki değerleri ekle';
     36$lang['Add information before'] = 'Önce bilgi ekleyiniz';
    3637?>
  • extensions/AddInfo/language/uk_UA/plugin.lang.php

    r14417 r21631  
    3434$lang['addinfo_info3'] = 'INFO3';
    3535$lang['addinfo_insing'] = 'вставити значення в базу даних';
     36$lang['Add information before'] = 'Додати інформацію до';
    3637?>
  • extensions/AddInfo/language/zh_CN/plugin.lang.php

    r17848 r21631  
    3434$lang['addinfo_explication_help'] = '这个插件是一个给图片增加备注信息的例子,你使用它,你得适应它。';
    3535$lang['addinfo_explication'] = '介绍';
     36$lang['Add information before'] = '添加信息(在之前)';
    3637?>
  • extensions/AddInfo/maintain.inc.php

    r7646 r21631  
    1515PRIMARY KEY (id))DEFAULT CHARSET=utf8;";
    1616        $result = pwg_query($query);
     17       
     18        $query = 'INSERT INTO ' . CONFIG_TABLE . ' (param,value,comment) VALUES ("AddInfo","datecreate","AddInfo");';
     19    pwg_query($query);
    1720
     21}
     22
     23function plugin_activate()
     24{
     25  global $conf;
     26  if (empty($conf['AddInfo']))
     27  {
     28        $query = 'INSERT INTO ' . CONFIG_TABLE . ' (param,value,comment) VALUES ("AddInfo","datecreate","AddInfo");';
     29    pwg_query($query);
     30  }
    1831}
    1932
     
    2437        $q = 'DROP TABLE ' . $prefixeTable . 'AddInfo_images;';
    2538    pwg_query($q);
     39       
     40        $q = 'DELETE FROM ' . CONFIG_TABLE . ' WHERE param="AddInfo" LIMIT 1;';
     41    pwg_query($q);
    2642}
    2743
Note: See TracChangeset for help on using the changeset viewer.