Ignore:
Timestamp:
2007/08/10 18:41:27 (17 years ago)
Author:
nanasess
Message:

コメント削除

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/feature-module-update/data/class/SC_View.php

    r15279 r15281  
    192192    } 
    193193} 
    194  
    195 //function sfCutString($str, $len, $byte = true, $commadisp = true) { 
    196 //        if($byte) { 
    197 //            if(strlen($str) > ($len + 2)) { 
    198 //                $ret =substr($str, 0, $len); 
    199 //                $cut = substr($str, $len); 
    200 //            } else { 
    201 //                $ret = $str; 
    202 //                $commadisp = false; 
    203 //            } 
    204 //        } else { 
    205 //            if(mb_strlen($str) > ($len + 1)) { 
    206 //                $ret = mb_substr($str, 0, $len); 
    207 //                $cut = mb_substr($str, $len); 
    208 //            } else { 
    209 //                $ret = $str; 
    210 //                $commadisp = false; 
    211 //            } 
    212 //        } 
    213 // 
    214 //        // 絵文字タグの途中で分断されないようにする。 
    215 //        if (isset($cut)) { 
    216 //            // 分割位置より前の最後の [ 以降を取得する。 
    217 //            $head = strrchr($ret, '['); 
    218 // 
    219 //            // 分割位置より後の最初の ] 以前を取得する。 
    220 //            $tail_pos = strpos($cut, ']'); 
    221 //            if ($tail_pos !== false) { 
    222 //                $tail = substr($cut, 0, $tail_pos + 1); 
    223 //            } 
    224 // 
    225 //            // 分割位置より前に [、後に ] が見つかった場合は、[ から ] までを 
    226 //            // 接続して絵文字タグ1個分になるかどうかをチェックする。 
    227 //            if ($head !== false && $tail_pos !== false) { 
    228 //                $subject = $head . $tail; 
    229 //                if (preg_match('/^\[emoji:e?\d+\]$/', $subject)) { 
    230 //                    // 絵文字タグが見つかったので削除する。 
    231 //                    $ret = substr($ret, 0, -strlen($head)); 
    232 //                } 
    233 //            } 
    234 //        } 
    235 // 
    236 //        if($commadisp){ 
    237 //            $ret = $ret . "..."; 
    238 //        } 
    239 //        return $ret; 
    240 //    } 
    241 // 
    242 //function sfRmDupSlash($istr){ 
    243 //        if(ereg("^http://", $istr)) { 
    244 //            $str = substr($istr, 7); 
    245 //            $head = "http://"; 
    246 //        } else if(ereg("^https://", $istr)) { 
    247 //            $str = substr($istr, 8); 
    248 //            $head = "https://"; 
    249 //        } else { 
    250 //            $str = $istr; 
    251 //        } 
    252 //        $str = ereg_replace("[/]+", "/", $str); 
    253 //        $ret = $head . $str; 
    254 //        return $ret; 
    255 //    } 
    256194?> 
Note: See TracChangeset for help on using the changeset viewer.