Skip to content

Commit d723cbd

Browse files
authored
Update 014-pdfJS-Static_PDF_Viewer.au3
1 parent 070c04b commit d723cbd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

examples/014-pdfJS-Static_PDF_Viewer.au3

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ Func __SetupStaticPDF(ByRef $oWeb, $s_PDF_Path, $bBlockLinks = False, $bBlockSel
188188

189189
; Fix slashes in Path for URL
190190
Local $s_PDF_URL = StringReplace($s_PDF_Path, "\", "/")
191-
$s_PDF_URL = StringReplace($s_PDF_URL, ' ', '%20')
191+
$s_PDF_URL = $oWeb.EncodeURI($s_PDF_URL)
192192
Local $s_PDF_JS_URL = StringReplace(@ScriptDir & "\JS_Lib\pdfjs\web\viewer.html" & "?file=", "\", "/")
193193
Local $s_Viewer_URL = "file:///" & $s_PDF_JS_URL & $s_PDF_URL
194194
ConsoleWrite("- $s_Viewer_URL= " & $s_Viewer_URL & @CRLF)

0 commit comments

Comments
 (0)