Changeset 2309 for branches

Show
Ignore:
Timestamp:
12/18/10 10:30:19 (17 months ago)
Author:
nick_ramsay
Message:

[1.5] Replaced table constants for some plugin-created tables per test #202

Location:
branches/1.5
Files:
4 modified

Legend:

Unmodified
Added
Removed
  • branches/1.5/install/install-upgrade.php

    r2277 r2309  
    239239 
    240240                // get old cvote data 
    241                 $sql = "SELECT * FROM " . TABLE_COMMENTVOTES; 
     241                $sql = "SELECT * FROM ".DB_PREFIX . "commentvotes"; 
    242242                $old_cvotes = $h->db->get_results($h->db->prepare($sql)); 
    243243                if ($old_cvotes) { 
     
    251251                 
    252252                // drop old commentvotes table 
    253                 $h->db->query("DROP TABLE " . TABLE_COMMENTVOTES); 
     253                $h->db->query("DROP TABLE ".DB_PREFIX."commentvotes"); 
    254254                 
    255255                // rename new table 
  • branches/1.5/libs/Caching.php

    r2166 r2309  
    207207                                break; 
    208208                        case 'commentvotes': 
    209                                 $sql = "SELECT cvote_updatedts FROM ".TABLE_COMMENTVOTES." ORDER BY cvote_updatedts DESC LIMIT 1"; 
     209                                $sql = "SELECT cvote_updatedts FROM ".DB_PREFIX."commentvotes ORDER BY cvote_updatedts DESC LIMIT 1"; 
    210210                                break; 
    211211                        case 'users': 
     
    213213                                break; 
    214214                        case 'useractivity': 
    215                                 $sql = "SELECT useract_updatedts FROM ".TABLE_USERACTIVITY." ORDER BY useract_updatedts DESC LIMIT 1"; 
     215                                $sql = "SELECT useract_updatedts FROM ".DB_PREFIX."useractivity ORDER BY useract_updatedts DESC LIMIT 1"; 
    216216                                break; 
    217217                        case 'usermeta': 
     
    225225                                break; 
    226226                        case 'friends': 
    227                                 $sql = "SELECT friends_updatedts FROM ".TABLE_FRIENDS." ORDER BY friends_updatedts DESC LIMIT 1"; 
     227                                $sql = "SELECT friends_updatedts FROM ".DB_PREFIX."friends ORDER BY friends_updatedts DESC LIMIT 1"; 
    228228                                break; 
    229229                        default: 
  • branches/1.5/libs/Comment.php

    r2292 r2309  
    352352 
    353353                // delete any votes for this comment 
    354                 $sql = "DELETE FROM ".TABLE_COMMENTVOTES." WHERE cvote_comment_id = %d"; 
     354                $sql = "DELETE FROM ".DB_PREFIX."commentvotes WHERE cvote_comment_id = %d"; 
    355355                $h->db->query($h->db->prepare($sql, $this->id)); 
    356356 
  • branches/1.5/libs/Initialize.php

    r2292 r2309  
    115115                        'TABLE_CATEGORIES' => 'categories', 
    116116                        'TABLE_COMMENTS' => 'comments', 
    117                         'TABLE_FRIENDS' => 'friends', 
    118                         'TABLE_MESSAGING' => 'messaging', 
    119117                        'TABLE_MISCDATA' => 'miscdata', 
    120118                        'TABLE_PLUGINS' => 'plugins', 
     
    122120                        'TABLE_PLUGINSETTINGS' => 'pluginsettings', 
    123121                        'TABLE_POSTS' => 'posts', 
    124                         'TABLE_POSTMETA' => 'postmeta', 
    125122                        'TABLE_POSTVOTES' => 'postvotes', 
    126123                        'TABLE_SETTINGS' => 'settings', 
     
    129126                        'TABLE_USERS' => 'users', 
    130127                        'TABLE_USERMETA' => 'usermeta', 
    131                         'TABLE_USERACTIVITY' => 'useractivity', 
    132128                        'TABLE_WIDGETS' => 'widgets', 
    133129                        'TABLE_TOKENS' => 'tokens'