~ubuntu-branches/ubuntu/lucid/phpmyadmin/lucid

« back to all changes in this revision

Viewing changes to libraries/common.lib.php

  • Committer: Bazaar Package Importer
  • Author(s): Thijs Kinkhorst
  • Date: 2008-06-14 15:24:31 UTC
  • mfrom: (1.1.20 upstream)
  • Revision ID: james.westby@ubuntu.com-20080614152431-gvx52c7r0iuxwvxl
Tags: 4:2.11.7~rc2-1
* New upstream release candidate.
  - Fixes an undisclosed security issue, which is most probably
    irrelevant to Debian, but medium urgency just in case.
  - Fixes session hash_bits override (Closes: #474557).
* Checked for policy 3.8.0, add README.source.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
/**
4
4
 * Misc functions used all over the scripts.
5
5
 *
6
 
 * @version $Id: common.lib.php 11183 2008-04-02 17:19:59Z lem9 $
 
6
 * @version $Id: common.lib.php 11299 2008-06-01 13:02:12Z lem9 $
7
7
 */
8
8
 
9
9
/**
1562
1562
    // display icon, even if iconic is disabled but the link-text is missing
1563
1563
    if (($GLOBALS['cfg']['MainPageIconic'] || empty($tab['text']))
1564
1564
        && isset($tab['icon'])) {
 
1565
        // avoid generating an alt tag, because it only illustrates
 
1566
        // the text that follows and if browser does not display
 
1567
        // images, the text is duplicated
1565
1568
        $image = '<img class="icon" src="' . htmlentities($GLOBALS['pmaThemeImage'])
1566
 
            .'%1$s" width="16" height="16" alt="%2$s" />%2$s';
 
1569
            .'%1$s" width="16" height="16" alt="" />%2$s';
1567
1570
        $tab['text'] = sprintf($image, htmlentities($tab['icon']), $tab['text']);
1568
1571
    }
1569
1572
    // check to not display an empty link-text
1967
1970
            // timestamp is numeric on some MySQL 4.1
1968
1971
            if ($meta->numeric && $meta->type != 'timestamp') {
1969
1972
                $condition .= '= ' . $row[$i] . ' AND';
1970
 
            } elseif ($meta->type == 'blob'
1971
 
                // hexify only if this is a true not empty BLOB
 
1973
            } elseif (($meta->type == 'blob' || $meta->type == 'string')
 
1974
                // hexify only if this is a true not empty BLOB or a BINARY
1972
1975
                 && stristr($field_flags, 'BINARY')
1973
1976
                 && !empty($row[$i])) {
1974
1977
                    // do not waste memory building a too big condition