diff -urp Orig/hidden_content/hidden_content.module New/hidden_content/hidden_content.module
--- Orig/hidden_content/hidden_content.module	2007-02-05 14:22:30.000000000 -0800
+++ New/hidden_content/hidden_content.module	2008-07-04 20:31:36.000000000 -0700
@@ -3,7 +3,6 @@
 
 /**
  * Implementation of hook_help().
- *
  */ 
 function hidden_content_help($section) {
   switch ($section) {
@@ -17,8 +16,8 @@ function hidden_content_help($section) {
  * Implementation of hook_filter_tips().
  *
  */
-function hidden_content_filter_tips($delta, $format, $long = false){
-  if($long){
+function hidden_content_filter_tips($delta, $format, $long = false) {
+  if ($long) {
     $text = "To make a part of your page hidden put it into [hidden] and [/hidden] tags.<br />\n";
     $text .= "You can specify which role is able to see the content by using the attribute role like this:<br />\n";
     $text .= "[hidden role=5]text[/hidden]. This will enable role 5 to see the text.\n<br />";
@@ -29,7 +28,8 @@ function hidden_content_filter_tips($del
     $text .= "[hidden role=2;3]text[/hidden]. This will enable role 2 and 3 to see the text.\n<br />";
     $text .= "If you ommit both parameters only user 1 will be able to see it.\n<br />";
     return t($text);
-  }else{
+  }
+  else {
     return t("You may insert [hidden]text[/hidden] into your text.");
   }
 }
@@ -38,8 +38,9 @@ function hidden_content_filter_tips($del
  * Implementation of hook_filter().
  *
  */
-function hidden_content_filter($op, $delta = 0, $format = -1, $text = ''){
+function hidden_content_filter($op, $delta = 0, $format = -1, $text = '') {
   global $user;
+  $access = user_access('view hidden content');
   switch ($op) {
     case 'no cache':
       return true;
@@ -53,50 +54,54 @@ function hidden_content_filter($op, $del
       return $text;
 
     case 'process':
-      if(!ereg('\[hidden',$text)){
+      if (!ereg('\[hidden', $text)) {
         return $text;
       }
-      $parts=explode('[hidden',$text);
-      $new_text=$parts[0];
-      for($part_num=1;$part_num<count($parts);$part_num++){
-        $part=$parts[$part_num];
-        if(ereg('^ role=([0-9;]+)\]',$part,$hit)){
-          $roles=$hit[1];
-          $part=ereg_replace('^ role=([0-9;]+)\]','',$part);
-          $show=false;
-          $roles=explode(';',$roles);
-          foreach($roles as $role){
-            if($user->roles[$role]!=""){
+      $parts = explode('[hidden', $text);
+      $new_text = $parts[0];
+      for ($part_num = 1; $part_num<count($parts); $part_num++) {
+        $part = $parts[$part_num];
+        if (ereg('^ role=([0-9;]+)\]', $part, $hit)) {
+          $roles = $hit[1];
+          $part = ereg_replace('^ role=([0-9;]+)\]', '', $part);
+          $show = false;
+          $roles = explode(';', $roles);
+          foreach ($roles as $role) {
+            if ($user->roles[$role] != "" || $access) {
               $show=true;
             }
           }
-        }else if(ereg('^ user=([0-9;]+)\]',$part,$hit)){
-          $users=$hit[1];
-          $part=ereg_replace('^ user=([0-9;]+)\]','',$part);
-          $show=false;
-          $users=explode(';',$users);
-          foreach($users as $user_id){
-            if($user->uid==$user_id){
-              $show=true;
+        }
+        else if (ereg('^ user=([0-9;]+)\]', $part, $hit)) {
+          $users = $hit[1];
+          $part = ereg_replace('^ user=([0-9;]+)\]', '', $part);
+          $show = false;
+          $users = explode(';', $users);
+          foreach ($users as $user_id) {
+            if ($user->uid == $user_id || $access) {
+              $show = true;
             }
           }
-        }else if(ereg('^\]',$part,$hit)){
-          $part=ereg_replace('^\]','',$part);
-          if($user->uid==1){
-            $show=true;
-          }else{
-            $show=false;
+        }
+        else if (ereg('^\]', $part, $hit)) {
+          $part = ereg_replace('^\]', '', $part);
+          if ($user->uid == 1 || $access) {
+            $show = true;
+          }
+          else {
+            $show = false;
           }
-        }else{
-          $show=false;
+        }
+        else {
+          $show = false;
         }
 
-        $small_parts=explode('[/hidden]',$part);
-        $first=array_shift($small_parts);
-        if($show){
-          $new_text.=$first;
+        $small_parts = explode('[/hidden]', $part);
+        $first = array_shift($small_parts);
+        if ($show) {
+          $new_text .= $first;
         }
-        $new_text.=implode('[/hidden]',$small_parts);
+        $new_text .= implode('[/hidden]', $small_parts);
       }
       return $new_text;
     break;
@@ -104,9 +109,9 @@ function hidden_content_filter($op, $del
 }
 
 /**
-* Valid permissions for this module
-* @return array An array of valid permissions for the onthisdate module
-*/
+ * Implementation of hook_perm().
+ * @return array An array of valid permissions for the hidden content module
+ */
 function hidden_content_perm() {
-  return array();
-} // function onthisdate_perm()
\ No newline at end of file
+  return array('view hidden content');
+}
\ No newline at end of file
