Admins can log into Users' accounts compatible with MyNetwork?
Shade Offline
Junior Member
**
Posts: 13
Joined: Jun 2012
Post: #3
RE: Admins can log into Users' accounts compatible with MyNetwork?
Actually, I easily succeeded into making both of them working together. Since you can't hook directly into MyNetwork's code - or you can, but not as you are used to - you have to insert admhijack template codes manually into your MyNetwork's templates. The code you have to insert manually is the following:

Code:
<li><a href="{$mybb->settings[\'bburl\']}/member.php?action=login&amp;do=hijack&amp;uid={$uid}&amp;my_post_key={$mybb->post_code}">Log in as this user</a></li>
<li><a href="{$mybb->settings[\'bburl\']}/member.php?action=logout&amp;do=regenkey&amp;uid={$uid}&amp;my_post_key={$mybb->post_code}">Force this user to log out (if logged in)</a></li>


I wouldn't recommend putting it into MYN's member_profile template just because admhijack_profile() function can't be hooked and consequently loaded within MYN. Since that function does nothing than a "Is moderator?" check, I suggest you to put those few lines of code into MYN's member_profile_modoptions or even better member_profile_adminoptions templates, performing the moderator (or admin) permission check by default.

09-29-2012 10:15 PM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

Messages In This Thread
RE: Admins can log into Users' accounts compatible with MyNetwork? - Shade - 09-29-2012 10:15 PM

 Standard Tools
Forum Jump: