diff --git a/layouts/shortcodes/codeimporter.html b/layouts/shortcodes/codeimporter.html
index 801697bc..493f4448 100644
--- a/layouts/shortcodes/codeimporter.html
+++ b/layouts/shortcodes/codeimporter.html
@@ -1,6 +1,6 @@
{{ $url := .Get "url" }}
{{ $type := .Get "type" }}
-{{ with resources.GetRemote (printf $url) }}
+{{ with resources.GetRemote (urls.Parse $url) }}
{{ $codeBlock := printf "```%s\n%s\n```" $type .Content }}
{{ $codeBlock | markdownify }}
{{ else }}
diff --git a/layouts/shortcodes/mdimporter.html b/layouts/shortcodes/mdimporter.html
index 28b24fe2..18b87bd6 100644
--- a/layouts/shortcodes/mdimporter.html
+++ b/layouts/shortcodes/mdimporter.html
@@ -1,6 +1,6 @@
{{ $url := .Get "url"}}
-{{ with resources.GetRemote (printf $url) }}
+{{ with resources.GetRemote (urls.Parse $url) }}
{{ .Content | markdownify }}
{{ else }}
{{ errorf "Mardown Importer Shortcode - Unable to get remote resource" . }}
-{{ end }}
\ No newline at end of file
+{{ end }}