Ignore:
Timestamp:
May 27, 2011, 11:02:05 PM (13 years ago)
Author:
nikrou
Message:

Fix incompatibility with piwigo 2.2
Change jquery plugin from fcbkcomplete to tokeninput

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/user_tags/include/t4u_content.class.php

    r9037 r11081  
    3030
    3131    if (!$this->plugin_config->hasPermission('add')) {
    32       return $content;
    33     }
    34 
    35     load_language('plugin.lang', T4U_PLUGIN_LANG);
    36 
    37     if (version_compare(PHPWG_VERSION, '2.2', '>=') || (PHPWG_VERSION=='Colibri')) {
    38       $template->func_combine_script(array('id' => 'jquery',
    39                                            'path' => 'themes/default/js/jquery.min.js'
    40                                            ),
    41                                      $template->smarty
    42                                      );
    43     } else {
    44       $template->func_known_script(array('id' => 'jquery',
    45                                          'src' => get_root_url().'themes/default/js/jquery.packed.js'
    46                                          ),
    47                                    $template->smarty
    48                                    );
     32      return false;
    4933    }
    5034
     
    5236    $template->assign('T4U_CSS', T4U_CSS);
    5337    $template->assign('T4U_IMGS', T4U_IMGS);
    54     $template->assign('T4U_ADD_SCRIPT', $this->plugin_config->getActionUrl($picture['url'], 'add'));
    55     $template->assign('T4U_GET_SCRIPT', $this->plugin_config->getActionUrl($picture['url'], 'get'));
     38    $template->assign('T4U_ADD_SCRIPT', $this->plugin_config->getActionUrl('add', 'GET'));
     39    $template->assign('T4U_GET_SCRIPT', $this->plugin_config->getActionUrl('get', 'GET'));
    5640    $template->assign('T4U_IMAGE_ID', $picture['id']);
    57     $template->assign('T4U_REFERER', htmlentities($picture['url']));
     41    $template->assign('T4U_REFERER', urlencode($picture['url']));
    5842    $template->assign('T4U_PERMISSION_DELETE', $this->plugin_config->hasPermission('delete'));
    5943
Note: See TracChangeset for help on using the changeset viewer.