Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

How to use Vanilla's forum accounts in my own site?

idaspinidaspin New
edited April 2015 in Vanilla 2.0 - 2.8

I have a page "" by example.
And "" - is Vanilla module(2.1.9)
How i can check UserGroupID from "" ?



  • Options
    idaspinidaspin New
    edited April 2015

    Ths. Could you give an example - how to use it?
    I mean this:

    <?php {/*Some code. Creating of $userIsAdmin*/;} if ($userIsAdmin) { /* my code of generating AdminPanel*/; } ?>
    <!DOCTYPE html>

  • Options

    What are you trying to to do? Create a single sign on experience, or check vanilla permissions?

    One thing you can do is create module in vanilla. You can load them through javascript on the client side, they will respect the permission of the session.

    grep is your friend.

  • Options

    I should check admin permision from non Vanilla page.

  • Options

    "" - the main site.
    In the folder "" I installed Vanillas forum.
    I have to do this: if the user is online and authorized, he is an administrator, then on the home page ("") displayed control panel.
    I do not know how to write this code.

  • Options
    hgtonighthgtonight ∞ · New Moderator

    Request the me module ( or profile ( from the vanilla installation via AJAX. This will give you the status of the user being signed in or not.

    Search first

    Check out the Documentation! We are always looking for new content and pull requests.

    Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.

  • Options
    x00x00 MVP
    edited April 2015

    Not really understanding you. Maybe you can write in your native language and perhaps somebody will able to translate.

    You want to be able to check permissions. Well you can do this server-server, but you need an API to do this, which is only available for 2.2 not yet officially released. It also carries a bit extra overhead to do the check every request.

    However another API, will work if you wish to load a vanilla module through javascript on the client side, and of-course respect the session, and permission checks for then module. This is the simplest solution, if applicable.

    However in a Single Sign On System. You are basically saying that the main site is goign to be the logon authority (you can also sync roles) over everything rather then vanilla. Therefore you mightn't have to check with vanilla, becuase you would already know based on the role.

    In Vanilla you normally check permissions not roles, as roles are assigned permissions and are subject to change.

    grep is your friend.

Sign In or Register to comment.