Changeset 1076 in ExiteCMS


Ignore:
Timestamp:
11/06/07 20:06:51 (4 years ago)
Author:
hverton
Message:

Fixed query giving the wrong result

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/locale_functions.php

    r1075 r1076  
    7878 
    7979        // get the last update date from the locale strings table 
    80         $result = dbquery("SELECT MAX(locales_datestamp) as last_update FROM ".$db_prefix." WHERE locales_locale = '".$settings['locale']."' AND locales_name = '".$locale_name."'"); 
     80        $data = dbarray(dbquery("SELECT MAX(locales_datestamp) as last_update FROM ".$db_prefix."locales WHERE locales_locale = '".$settings['locale']."' AND locales_name = '".$locale_name."'")); 
    8181 
    8282        // if found... 
    83         if ($data = dbarray($result)) { 
     83        if ($data['last_update']) { 
    8484 
    8585            // if the locales cache does not exist or is out of date... 
     
    8787 
    8888                // compile the locales cache file from the locales table 
    89                 if ($handle = fopen($locales_file, 'w')) { 
     89                if ($handle = @fopen($locales_file, 'w')) { 
    9090 
    9191                    // get the locale records for the selected locale and this locale_name 
Note: See TracChangeset for help on using the changeset viewer.