| « custom display for specific groups | Embed Flash 2.2 » |
This is a great little piece of code for b2evo… thank ¥åßßå. I wanted to display something custom for each specific user. This code will detect the users ID # and display, for their eyes only, whatever you have in the echo line. Beautiful!
Simply enter the users ID # for each case and then enter in the information you want them to see in the echo line. You can enter this code into any of your skin files where you want the information to display.
Code:
<?php | |
if( empty( $current_User ) ) | |
{ // not logged in | |
} | |
else | |
{ // logged in | |
switch( $current_User->ID ) | |
{ | |
case 1 : | |
echo 'ID 1 can see this'; | |
break; | |
case 2 : | |
echo 'ID 2 can see this'; | |
break; | |
case 3 : | |
echo 'ID 3 can see this'; | |
break; | |
default : | |
} | |
} | |
?> |
You can also do this for an entire user group. b2evo - custom display for specific groups
What else can you do with this? How about put a style sheet link and change up your skins look for a specific user! Run a script for one user! Enter privileged information for each user! The possibilities are endless!