Add name of mask to page, for later use in JavaScript
authorJoey Schulze <joey@infodrom.org>
Thu, 4 Mar 2010 10:17:58 +0000 (11:17 +0100)
committerJoey Schulze <joey@infodrom.org>
Thu, 4 Mar 2010 10:17:58 +0000 (11:17 +0100)
lib/mask.php

index 8549ee4..a63d883 100644 (file)
@@ -231,8 +231,8 @@ function mask($name)
   if (array_key_exists('table',$mask) && array_key_exists('list',$mask))
     $ret = build_mask($name, $mask);
 
   if (array_key_exists('table',$mask) && array_key_exists('list',$mask))
     $ret = build_mask($name, $mask);
 
-  error_log(count($ret));
-  return implode("\n", $ret);
+  return sprintf('<span id="source" style="display: none;">%s</span>', $_GET['mask'])
+    . implode("\n", $ret);
 }
 
 }
 
-?>
\ No newline at end of file
+?>