From 34dd8f3158bc6d5483d7828ebfa3d26e6a7b200a Mon Sep 17 00:00:00 2001 From: kevin_fourie Date: Fri, 29 Jun 2007 14:53:57 +0000 Subject: [PATCH] KTS-2148 "Security Information Warning in Internet Explorer (IE) when viewing documents folders." Fixed/In Progress/Updated. Description of work done... --- plugins/rssplugin/KTrss.inc.php | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/plugins/rssplugin/KTrss.inc.php b/plugins/rssplugin/KTrss.inc.php index 40fffd6..fd406c3 100644 --- a/plugins/rssplugin/KTrss.inc.php +++ b/plugins/rssplugin/KTrss.inc.php @@ -259,7 +259,8 @@ class KTrss{ function arrayToXML($aItems){ // Build path to host $aPath = explode('/', trim($_SERVER['PHP_SELF'])); - $hostPath = "http://".$_SERVER['HTTP_HOST']."/".$aPath[1]."/"; + global $default; + $hostPath = "http" . ($default->sslEnabled ? "s" : "") . "://".$_SERVER['HTTP_HOST']."/".$aPath[1]."/"; $feed = "\n"; $feed .= "\n". "\n" . @@ -371,7 +372,8 @@ class KTrss{ function errorToXML($sError){ // Build path to host $aPath = explode('/', trim($_SERVER['PHP_SELF'])); - $hostPath = "http://".$_SERVER['HTTP_HOST']."/".$aPath[1]."/"; + global $default; + $hostPath = "http" . ($default->sslEnabled ? "s" : "") . "://".$_SERVER['HTTP_HOST']."/".$aPath[1]."/"; $feed = "\n"; $feed .= "\n". "\n" . @@ -495,7 +497,8 @@ class KTrss{ // get icon link for rss function getRssLinkIcon(){ // built server path - $sHostPath = "http://".$_SERVER['HTTP_HOST']."/".$GLOBALS['KTRootUrl']."/"; + global $default; + $sHostPath = "http" . ($default->sslEnabled ? "s" : "") . "://".$_SERVER['HTTP_HOST']."/".$GLOBALS['KTRootUrl']."/"; // create image $icon = "RSS"; @@ -513,7 +516,8 @@ class KTrss{ } // built server path - $sHostPath = "http://".$_SERVER['HTTP_HOST']; + global $default; + $sHostPath = "http" . ($default->sslEnabled ? "s" : "") . "://" . $_SERVER['HTTP_HOST']; // build link $sLink = $sHostPath.KTBrowseUtil::buildBaseUrl('rss').$sItemParameter.'='.$iItemId; @@ -540,17 +544,19 @@ class KTrss{ // get mime information for a document function getMimeTypeInfo($iUserId, $iDocumentId){ + global $default; $mimeinfo['typeId'] = KTrss::getDocumentMimeTypeId($iUserId, $iDocumentId); // mime type id $mimeinfo['typeName'] = KTMime::getMimeTypeName($mimeinfo['typeId']); // mime type name $mimeinfo['typeFName'] = KTMime::getFriendlyNameForString($mimeinfo['typeName']); // mime type friendly name - $mimeinfo['typeIcon'] = "http://".$_SERVER['HTTP_HOST']."/".$GLOBALS['KTRootUrl']."/resources/mimetypes/".KTMime::getIconPath($mimeinfo['typeId']).".png"; //icon path + $mimeinfo['typeIcon'] = "http" . ($default->sslEnabled ? "s" : "") . "://".$_SERVER['HTTP_HOST']."/".$GLOBALS['KTRootUrl']."/resources/mimetypes/".KTMime::getIconPath($mimeinfo['typeId']).".png"; //icon path return $mimeinfo; } // get the default folder icon function getFolderIcon(){ - return $mimeinfo['typeIcon'] = "http://".$_SERVER['HTTP_HOST']."/".$GLOBALS['KTRootUrl']."/thirdparty/icon-theme/16x16/mimetypes/x-directory-normal.png"; //icon path + global $default; + return $mimeinfo['typeIcon'] = "http" . ($default->sslEnabled ? "s" : "") . "://".$_SERVER['HTTP_HOST']."/".$GLOBALS['KTRootUrl']."/thirdparty/icon-theme/16x16/mimetypes/x-directory-normal.png"; //icon path } // get a document information -- libgit2 0.21.4