XPressME Integration Kit

Trac

Changeset 485


Ignore:
Timestamp:
Dec 11, 2009, 4:32:34 PM (14 years ago)
Author:
toemon
Message:

統計情報にno_name統計が表示されるバグ修正 Fixes#269

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/xpressme_integration_kit/include/general_functions.php

    r423 r485  
    126126                $table_list = array(); 
    127127                $ret = array(); 
     128                $pattern = $wp_prefix . $table_name . '|' . $wp_prefix . '[0-9]*_' . $table_name; 
     129 
    128130                if (!empty($wp_prefix) && !empty($table_name)){ 
    129131                        $sql = "SHOW TABLES LIKE '" . $wp_prefix  . '%' . $table_name . "'"; 
     
    132134                                if($result = $xoopsDB->queryF($sql)){ 
    133135                                        while($row = $xoopsDB->fetchRow($result)){ 
    134                                                 $table_list[] = $row[0]; 
     136                                                if(preg_match('/' . $pattern . '/' , $row[0])){ 
     137                                                        $table_list[] = $row[0]; 
     138                                                } 
    135139                                        } 
    136140                                } 
     
    138142                                $rows = $xoops_db->get_results($sql, ARRAY_N); 
    139143                                foreach ($rows as $row){ 
    140                                         $table_list[] = $row[0]; 
     144                                        if(preg_match('/' . $pattern . '/' , $row[0])){ 
     145                                                $table_list[] = $row[0]; 
     146                                        } 
    141147                                } 
    142148                        }                        
Note: See TracChangeset for help on using the changeset viewer.