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.

Problem when using SSO with Embedding plugin

I am currently using Vanilla with a Drupal site. The SSO works fine with jsConenct. I set Vanilla to use only SSO so user accounts can only be created on Drupal site.

Then I embed vanilla into the Drupal site, which also works fine. Except, if a visitor comes to the forum page and trigger any login/register link, my Drupal login/register page will be opened inside the iframe. So it ends at a Drupal-in-Drupal page...

Is there any way I can set all those login/register page to open in current page (i.e. to set target="_parent" for the )?


  • I ended up with directly hacking into jsconnect plugin - would be better to have this as an option in plugin admin UI though:

    diff --git a/plugins/jsconnect/class.jsconnect.plugin.php b/plugins/jsconnect/class.jsconnect.plugin.php
    index 339ce96..8f8b2e2 100644
    --- a/plugins/jsconnect/class.jsconnect.plugin.php
    +++ b/plugins/jsconnect/class.jsconnect.plugin.php
    @@ -54,12 +54,12 @@ class JsConnectPlugin extends Gdn_Plugin {
           $RegisterUrl = FormatString(GetValue('RegisterUrl', $Provider, ''), $Data);
           if ($RegisterUrl)
    -          $RegisterLink = ' '.Anchor(sprintf(T('Register with %s', 'Register'), $Provider['Name']), $RegisterUrl, 'Button RegisterLink', array('target' => '_parent'));
    +          $RegisterLink = ' '.Anchor(sprintf(T('Register with %s', 'Register'), $Provider['Name']), $RegisterUrl, 'Button RegisterLink');
              $RegisterLink = '';
           $Result = '<div style="display: none" class="JsConnect-Container ConnectButton Small UserInfo" rel="'.$Url.'">
    -         <div class="JsConnect-Guest">'.Anchor(sprintf(T('Sign In with %s'), $Provider['Name']), $SignInUrl, 'Button SignInLink', array('target' => '_parent')).$RegisterLink.'</div>
    +         <div class="JsConnect-Guest">'.Anchor(sprintf(T('Sign In with %s'), $Provider['Name']), $SignInUrl, 'Button SignInLink').$RegisterLink.'</div>
              <div class="JsConnect-Connect"><a class="PopupWindow ConnectLink" popupHeight="300" popupWidth="600">'.Img('/applications/dashboard/design/images/usericon.gif', array('class' => 'ProfilePhotoSmall UserPhoto')).'<span class="Username"></span><div class="ConnectLabel">'.sprintf(T('Sign In with %s'), $Provider['Name']).'</div></a></div>
  • @1a0 Were you using the embedded SSO? (With the window.vanilla_sso object?) Can you please post the php code you used to generate the vanilla_sso string?

    Thank you,

Sign In or Register to comment.