2 Commits 042d6442ce ... 12619387f5

Autore SHA1 Messaggio Data
  k4be 12619387f5 Jeszcze jedna poprawka plików ze spacjami 10 mesi fa
  k4be 1a4b6a6f93 Poprawa URL obrazków ze spacjami w nazwie 10 mesi fa
2 ha cambiato i file con 5 aggiunte e 5 eliminazioni
  1. 1 1
      dir.php
  2. 4 4
      image.php

+ 1 - 1
dir.php

@@ -16,7 +16,7 @@ if (!$dirinfo) {
 $images = get_dir_images($dir, $mode);
 $content = '';
 foreach ($images as $image) {
-	$path = urlencode($image['path']);
+	$path = rawurlencode($image['path']);
 	$content .= '<a href="image.php?dir='.$dir.'&amp;file='.$path;
 	if ($mode) {
 		$content .= '&mode=' . urlencode($mode);

+ 4 - 4
image.php

@@ -39,8 +39,8 @@ if (!$fileinfo) {
 	die('File not found');
 }
 
-$dirhtml = urlencode($dirinfo['path']);
-$filehtml = urlencode($fileinfo['path']);
+$dirhtml = rawurlencode($dirinfo['path']);
+$filehtml = rawurlencode($fileinfo['path']);
 if ($mode) {
 	$modehtml = '&mode=' . urlencode($mode);
 } else {
@@ -49,7 +49,7 @@ if ($mode) {
 
 $content = '<div class="full-image-div"><a class="gora" href="dir.php?dir='.$dirhtml.$modehtml.'"></a><a id="poprz" ';
 if ($prev) {
-	$prevhtml = urlencode($prev['path']);
+	$prevhtml = rawurlencode($prev['path']);
 	$content .= 'href="image.php?file='.$prevhtml.'&amp;dir='.$dirhtml.$modehtml.'"';
 } else {
 	$content .= 'style="display:none;"';
@@ -57,7 +57,7 @@ if ($prev) {
 
 $content .= '></a><div><a id="imagelink"';
 if ($next) {
-	$nexthtml = urlencode($next['path']);
+	$nexthtml = rawurlencode($next['path']);
 	$content .= ' href="image.php?file='.$nexthtml.'&amp;dir='.$dirhtml.$modehtml.'"';
 }
 $content .= '><img id="image" src="'.$config['imagepath'] . $dirhtml.'/'.$filehtml.'" class="pelny"/></a><a id="nast" ';