ここの情報は古いです。ご理解頂いた上でお取り扱いください。

Changeset 12395


Ignore:
Timestamp:
Jul 26, 2009, 6:11:46 PM (11 years ago)
Author:
ebihara
Message:

#4134:fixed op_truncate_callback() function that truncates with a width that is included wrong length of specified trimmarker

File:
1 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE3/trunk/lib/helper/opUtilHelper.php

    r12308 r12395  
    481481function op_truncate_callback($string, $width, $etc = '')
    482482{
     483  $width = $width - mb_strwidth($etc);
     484
    483485  if (mb_strwidth($string) > $width)
    484486  {
     
    520522    }
    521523
    522     $string = mb_strimwidth($string, 0, $width, $etc, 'UTF-8');
     524    $string = mb_strimwidth($string, 0, $width, '', 'UTF-8');
    523525  }
    524526
Note: See TracChangeset for help on using the changeset viewer.