From 91e519fd9607bd6a56df38d08fcf87730cf5ebaf Mon Sep 17 00:00:00 2001 From: tmos Date: Sun, 4 May 2014 14:57:39 +0200 Subject: [PATCH] universal gallery link in php ! --- config.php | 2 +- rss.php | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/config.php b/config.php index 57e269f..47f4582 100755 --- a/config.php +++ b/config.php @@ -38,7 +38,7 @@ $label_noimages = "No images"; //Empty folder text $label_loading = "Loading..."; //Thumbnail loading text //RSS SETTINGS -$gallery_link = "http://you.minigal.adress/"; //don't forget the final / ! +$gallery_link = substr("http://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'], 0, strlen("http://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'])-7); // the -7 is to remove "rss.php" $description = "MiniGal Nano"; $nb_items_rss = 25; //number ef elements to display in the feed. If you add a lot of pictures at the time, consider increasing this number $SkipExts = array('html', 'txt', 'php', "gitignore"); //Files with one of this extension will not be displayed on the RSS feed diff --git a/rss.php b/rss.php index f11036d..a4aa97a 100644 --- a/rss.php +++ b/rss.php @@ -20,7 +20,6 @@ $FileExt = strtolower(substr(strrchr($Current ,'.'),1)); if (in_array($FileExt, $SkipFileExts)===false) // Should we display this extension ? $current_adress = $gallery_link . "/" . $Folder.'/'. $Current; - #debug echo "display current_adress : ". $current_adress . "
"; $content .= $current_adress. "\n"; } }