Ignore:
Timestamp:
Apr 4, 2006, 2:35:12 AM (18 years ago)
Author:
rvelices
Message:

fix: sql query erros when: no items for the selected tag, search returns
no result, caddie is empty

fix: tag cloud was showing least used tags

fix: strip html tags from head/title element on the page
(tag index page title contained <a>...)

improvement: added 5 tag levels in css for "ready to use" tags

fix: corrected png icon calendar_created.png for IE

fix: english language for nbm

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/section_init.inc.php

    r1119 r1120  
    162162      }
    163163    }
    164    
     164
    165165    array_push(
    166166      $page['tags'],
     
    306306        'uppercats'        => $result['uppercats'],
    307307
    308         'title' => get_cat_display_name($result['name'], null, false),
     308        'title' => get_cat_display_name($result['name'], '', false),
    309309        )
    310310      );
     
    361361    // reachable to the connected user, we need to check category
    362362    // associations
    363     if (!empty($user['forbidden_categories']))
     363    if (!empty($user['forbidden_categories']) and !empty($items) )
    364364    {
    365365      $query = '
     
    382382    $result = pwg_query($query);
    383383    $tag_infos = array();
    384    
     384
    385385    while ($row = mysql_fetch_array($result))
    386386    {
     
    429429    include_once( PHPWG_ROOT_PATH .'include/functions_search.inc.php' );
    430430
    431     $query = '
     431    $search_items = get_search_items($page['search']);
     432    if ( !empty($search_items) )
     433    {
     434      $query = '
    432435SELECT DISTINCT(id)
    433436  FROM '.IMAGES_TABLE.'
    434437    INNER JOIN '.IMAGE_CATEGORY_TABLE.' AS ic ON id = ic.image_id
    435   WHERE id IN ('.implode(',', get_search_items($page['search'])).')
     438  WHERE id IN ('.implode(',', $search_items).')
    436439    AND '.$forbidden.'
    437440  '.$conf['order_by'].'
    438 ;';
     441;';
     442      $page['items'] = array_from_query($query, 'id');
     443    }
     444    else
     445    {
     446      $page['items'] = array();
     447    }
    439448
    440449    $page = array_merge(
     
    442451      array(
    443452        'title' => $lang['search_result'],
    444         'items' => array_from_query($query, 'id'),
    445453        'thumbnails_include' => 'include/category_default.inc.php',
    446454        )
Note: See TracChangeset for help on using the changeset viewer.