Version: , by Tim Wheatley
Developer Last Online: Dec 2021
Version: Unknown
Rating:
Released: 09-07-2002
Last Update: Never
Installs: 0
No support by the author.
Insert this into phpinclude template:
Code:
// hide feature from unregistered
if ($bbuserinfo['userid']<"1") {
$unregopen = "<!-- ";
} else {
$unregopen = "";
}
// hide feature from unregistered
// hide feature from unregistered
if ($bbuserinfo['userid']<"1") {
$unregclose = " -->";
} else {
$unregclose = "";
}
// hide feature from unregistered
Then if you want to hide something place
$unregopen before it and $unregclose after it.
This is someone elses hack to show the register button to guests and the cp button to members, but i changed it for this, I feel quietly pleased with myself.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
ProgS - you do not put anything of your own into the phpinclude template - you put the code exactly as Tim has posted in the first post.
Then, in any template, like he said, if you don't want something to show up for an unregistered user, you comment it out with HTML using the function that you have just pasted by adding the commenting out tags.
Read his first post carefully - he explains it quite well.
Good idea Tim. You can make this into a hack, by placing the same code in global.php.
you havent understand what I mean!!!
but in the other thread of me I got the answer for my problem!
I had exactly this script included like in the first post!
I can use this variables in the header-template, okay...
but NOT in the postbit-template!!!
I dont know why, but it is so...
Originally posted by Xenon this is the code i use in my phpinclude:
...
it works on most of the templates, but not on postbit??
it think it has something to do with the repeating...
i hope i'll find out
thxxx!
nice to see that somebody understand me!!!
I still spend to much time for this prob...
I hope in version 3 it is solved, and then the pics an links are only to see if the user has the permissions for it....
great idea, i can also see how a slight modification of this hack would assist in creating a usergroup with limited features.
for instance, i have a user on my board that insists on using a post icon designated for mature/adult type posts only and does so on every one of his posts out of context despite being asked not to repeatedly. i don't want to ban him but with a mod of this hack, i can remove the post icon section entirely from his view, plus other features like smilies and any other features that are abused.
i have yet to install this hack but i will try tonight. last night i tried and fubared my functions.php file (don't ask) but i was not at my own computer with all my backup files like i will be tonight.