Ignore:
Timestamp:
Mar 6, 2013, 1:54:04 PM (11 years ago)
Author:
plg
Message:

compatibility with Piwigo 2.5: replace functions mysql_* with pwg_db_* equivalent

switch version to "auto"

use the new $template->add_index_button function

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/piclens/include/Piclens.class.php

    r9448 r21238  
    8484                                                $piclnkMaster='';
    8585                                                $result = pwg_query($query);
    86                                                 while ($row = mysql_fetch_assoc($result))
     86                                                while ($row = pwg_db_fetch_assoc($result))
    8787                                                {
    8888                                                        // Gestion des permalinks
     
    150150                                                        $result = pwg_query($query);
    151151
    152                                                         while ($row = mysql_fetch_assoc($result))
     152                                                        while ($row = pwg_db_fetch_assoc($result))
    153153                                                        {
    154154                                                                if (!(in_array($row['id'], explode(',', $user['forbidden_categories']))))
     
    193193                                                        $result = pwg_query($query);
    194194
    195                                                         while ($row = mysql_fetch_array($result))
     195                                                        while ($row = pwg_db_fetch_assoc($result))
    196196                                                        {
    197197                                                                $piclnkMaster.='<link rel="alternate"'
     
    283283                                                $tpl_code='<li><img src="'.$this->root_site_piclens.PICLENS_IMG_PATH.'cooliris-icon-black.png" NAME="but1" class="button" alt="'.l10n('piclens_button').'" width="24" height="24"></a></li>';
    284284                                }
     285       
    285286                                if (isset($tpl_code))
    286                                         $template->concat('PLUGIN_INDEX_ACTIONS', $tpl_code."\n");
     287        {
     288          $template->add_index_button($tpl_code, 100);
     289        }
    287290                        }
    288291                       
     
    318321            if($result)
    319322                {
    320                      $row = mysql_fetch_row($result);
     323                     $row = pwg_db_fetch_row($result);
    321324                     if(is_string($row[0]))
    322325                         {
Note: See TracChangeset for help on using the changeset viewer.