<?php
/*
''~``
( o o )
+------------------.oooO--(_)--Oooo.------------------+
| Unreal Hide Hack 2.1 |
| .oooO |
| ( ) Oooo. |
+---------------------\ (----( )--------------------+
\_) ) /
(_/
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|The Logo Looks Best in Courier New|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
---====---
Unreal Hide Hack 2.1 for IBF v2.3.0
By Cricket
*/
if ( ! defined( 'IN_IPB' ) )
{
print "<h1>Incorrect access</h1>You cannot access this file directly. If you have recently upgraded, make sure you upgraded all the relevant files.";
exit();
}
class hide
{
function parse($post, $topicid)
{
//-----------------------------------------
// Unreal Hide Hack
//-----------------------------------------
if((preg_match("#\[hide_me\](.+?)\[/hide_me\]#is", $post)) || (preg_match("#\[hide\](.+?)\[/hide\]#is", $post)))
{
$this->ipsclass->DB->query("SELECT post_thanks, author_id FROM ibf_posts WHERE topic_id='".$topicid."'");
while($info = $this->ipsclass->DB->fetch_row())
{
$allposters[] = $info['post_thanks'];
$allposters[] = $info['author_id'];
}
if($allposters != null)
{
$allposters = implode(",",$allposters);
$allposters = explode(",",$allposters);
if(
in_array($this->ipsclass->member['id'], $allposters)
OR
in_array( $this->ipsclass->member['mgroup'], array(4, 7, 9) ))
{
$post = preg_replace( "#\[hide_me\](.+?)\[/hide_me\]#is", "<{HIDE2}> \\1", $post );
$post = preg_replace( "#\[hide\](.+?)\[/hide\]#is", "<{HIDE2}> \\1", $post );
}
else
{
$post = preg_replace( "#\[hide_me\](.+?)\[/hide_me\]#is", "<{HIDE1}>", $post );
$post = preg_replace( "#\[hide\](.+?)\[/hide\]#is", "<{HIDE1}>", $post );
}
}
else
{
$post = preg_replace( "#\[hide_me\](.+?)\[/hide_me\]#is", "<{HIDE1}>", $post );
$post = preg_replace( "#\[hide\](.+?)\[/hide\]#is", "<{HIDE1}>", $post );
}
}
return $post;
}
}
?>