diff --git a/protected_node.fork.inc b/protected_node.fork.inc
index 2e9cc15..1b4df3e 100644
--- a/protected_node.fork.inc
+++ b/protected_node.fork.inc
@@ -146,7 +146,7 @@ function protected_node_enter_any_password() {
   // Add a cancel link when 'back' is defined (i.e. refers on the previous
   // page).
   if (isset($_GET['back'])) {
-    $cancel = $_GET['back'];
+    $cancel = urldecode($_GET['back']);
   }
   elseif (variable_get('protected_node_cancel', 0)) {
     $cancel = '<front>';
diff --git a/protected_node.redirect.inc b/protected_node.redirect.inc
index 73a9a93..422677e 100644
--- a/protected_node.redirect.inc
+++ b/protected_node.redirect.inc
@@ -132,14 +132,15 @@ function protected_node_enterpassword() {
   // Add a cancel link when 'back' is defined (i.e. referer on the previous
   // page).
   if (isset($_GET['back'])) {
-    $cancel = $_GET['back'];
+    $cancel = urldecode($_GET['back']);
   }
   elseif (variable_get('protected_node_cancel', 0)) {
     $cancel = '<front>';
   }
   if (!empty($cancel)) {
     $form['protected_node_enterpassword']['cancel'] = array(
-      '#value' => l(t('Cancel'), $cancel),
+      '#type' => 'markup',
+      '#markup' => l(t('Cancel'), $cancel),
     );
   }
 
