From: x2003bruneau Date: Fri, 2 Nov 2007 23:44:04 +0000 (+0000) Subject: Fix URL conflict when the same spool is used on different site. X-Git-Tag: 1.8~7 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=abaec8203ac4c490e0dcf6839fe7f249de58fe4a;hp=69f4f159be61a868e6dda95deb2e58a93e94d546;p=banana.git Fix URL conflict when the same spool is used on different site. This distinction is made on the host name only (conflicts may remain if the same group is displayed on different pathes of the same site). Signed-off-by: Florent Bruneau git-svn-id: svn+ssh://murphy/home/svn/banana/trunk@304 9869982d-c50d-0410-be91-f2a2ec7c7c7b --- diff --git a/banana/tree.inc.php b/banana/tree.inc.php index 667925f..09fe261 100644 --- a/banana/tree.inc.php +++ b/banana/tree.inc.php @@ -151,7 +151,11 @@ class BananaTree */ static private function filename($id) { - return BananaSpool::getPath('tree_' . $id); + static $host; + if (!isset($host)) { + $host = parse_url(Banana::$page->makeURL(array()), PHP_URL_HOST); + } + return BananaSpool::getPath('tree_' . $id . '_' . $host); } /** Read a tree from a file diff --git a/css/style.css b/css/style.css index 8d0a405..eb3a964 100644 --- a/css/style.css +++ b/css/style.css @@ -46,7 +46,7 @@ padding-left: 1ex; border-left: solid 1px; border-color: blue; - background: inherit; + background: inherit; } .banana table.message blockquote blockquote { color: green;