Index: trunk/kernel/include/image.php =================================================================== diff -u -N -r1015 -r1054 --- trunk/kernel/include/image.php (.../image.php) (revision 1015) +++ trunk/kernel/include/image.php (.../image.php) (revision 1054) @@ -474,8 +474,12 @@ { global $rootURL, $objConfig,$pathtoroot; - if($this->Get("SameImages") && !$ForceNoThumb) - return $this->ThumbURL(); + if($this->Get('SameImages') && !$ForceNoThumb) + if (!(($this->Get('LocalImage') && strlen($this->Get('LocalPath'))) || + ($this->Get('LocalImage') == 0 && strlen($this->Get('Url'))))) + { + return $this->ThumbURL(); + } if(strlen($this->Get("Url"))) return $this->Get("Url"); Index: trunk/globals.php =================================================================== diff -u -N -r1020 -r1054 --- trunk/globals.php (.../globals.php) (revision 1020) +++ trunk/globals.php (.../globals.php) (revision 1054) @@ -1044,7 +1044,7 @@ { global $objSystemCache, $objSession, $objConfig; - if($objConfig->Get("SystemTagCache")) + if($objConfig->Get("SystemTagCache") && !$objSession->Get('PortalUserId')) { $name = $tag; if(is_array($attribs)) Index: trunk/admin/include/checkarray.js =================================================================== diff -u -N -r326 -r1054 --- trunk/admin/include/checkarray.js (.../checkarray.js) (revision 326) +++ trunk/admin/include/checkarray.js (.../checkarray.js) (revision 1054) @@ -163,7 +163,9 @@ function check_submit(location, ActionValue, EnvVar) { if( ActionValue.match(/_del/) || ActionValue.match(/del_/) ) + { if (!theMainScript.Confirm(lang_DeleteConfirm)) return; + } f = document.getElementById(this.formname); if(f) Index: trunk/kernel/action.php =================================================================== diff -u -N -r1041 -r1054 --- trunk/kernel/action.php (.../action.php) (revision 1041) +++ trunk/kernel/action.php (.../action.php) (revision 1054) @@ -1225,6 +1225,7 @@ if($objSession->HasSystemPermission("DEBUG.LIST")) echo $sql."
\n"; $ado->Execute($sql); +// $t->Files->FindMissingFiles(strtolower($t->Get('name'))); } break; case "m_theme_edit": Index: trunk/kernel/include/theme.php =================================================================== diff -u -N -r1016 -r1054 --- trunk/kernel/include/theme.php (.../theme.php) (revision 1016) +++ trunk/kernel/include/theme.php (.../theme.php) (revision 1054) @@ -497,17 +497,29 @@ { fwrite($fp,''); fclose($fp); +// $this->Files->FindMissingFiles($this->Get('name')); + /* $theme_id = $this->Get('ThemeId'); + $db_dir = '/'.strtolower($this->Get('Name')); + $sql = 'INSERT INTO '.GetTablePrefix().'ThemeFiles + (ThemeId, FileName, FilePath, Description, FileType) VALUES + ('.$theme_id.', "index.tpl", "'.$db_dir.'", "", 0)'; + $conn = &GetADODBConnection(); + $conn->Execute($sql);*/ } - } } function Delete() { $this->Files->DeleteAll(); $dir = $this->ThemeDirectory(); - if(is_writable($dir)) + if(is_writable($dir)) { + $files = filelist($dir); + foreach ($files as $file) { + @unlink($file); + } @rmdir($dir); + } parent::Delete(); } @@ -616,7 +628,7 @@ { $sql = "UPDATE ".$this->SourceTable." SET PrimaryTheme=0 WHERE ThemeId != ".$t->Get("ThemeId"); $this->adodbConnection->Execute($sql); - } + } return $t; } @@ -645,7 +657,7 @@ function DeleteTheme($ThemeId) { $t = $this->GetItem($ThemeId); - $t->Delete(); + if (!$t->Get('PrimaryTheme')) $t->Delete(); } function SetPrimaryTheme($ThemeId) @@ -753,6 +765,7 @@ { $c->UnsetIdField(); $c->Create(); + $GLOBALS['m_var_list']['theme_id']=$c->Get('ThemeId'); $c->CreateDirectory(); } if($c->Get("PrimaryTheme"))