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.
Options

Sign-in works, but does not refresh page!

I'm having an issue where using the sign in form does not refresh the home page, so the user DOES get signed in successfully, but doesn't know it because the page doesn't update. I've seen this issue on a lot of posts, but have not found a solution. Please help!

Some info:

  • Using Vanilla 2.1.10
  • Using Facebook and Twitter Sign In Plugins
  • Using Bootstrap Theme (does not seem to be the source of the issue)

Reproduction steps:

  • Click sign in button
  • Sign in window appears
  • Attempt to log in with valid username and password
  • (Sometimes 50/50, I get a red "Please Try Again" error, which goes away if I try again)
  • When sign in window closes, nothing refreshes.
  • In order to see myself as logged in, I need to press "Categories" or enter a Discussion. (not even F5 refreshing works(

Other fun facts:

  • This happens on multiple different computers, user names, and browsers (Firefox and Chrome)
  • I installed Vanilla via my GoDaddy hosting account, and then manually upgraded following all the steps listed in the Vanilla documentation.
  • I really think this is some sort of caching issue, but I'm not too familiar with Vanilla's inner workings and I'm afraid to mess up my install.
  • No javascript errors pop up in my console in Google Chrome.

Forum in question:
http://www.hivejump.com/community
(set in invite-only mode right now, but happy to invite anyone who can help troubleshoot)

Thanks in advance for any help you can give!

«1

Comments

  • Options
    kamaleonkamaleon New
    edited June 2015

    Have you setup your smtp email?

    Settings > Outgoing Email

  • Options
    K17K17 Français / French Paris, France ✭✭✭

    Do you using the NoCaptcha Recaptcha addon?

  • Options

    I am not using the "NoCaptcha Recaptcha" addon or plugin.

    I have not set up the SMTP email. See screenshot.

    Will setting up the SMTP e-mail fix the sign-in issue?

  • Options

    Yes, it should.

    But I was not using any plugins for facebook signin, just the default tool inside Forum > Social

  • Options

    I'm not using plugins for social sign-in either. Just through the Social options pane in the Dashboard.

    I'll try SMTP e-mail, but I'm skeptical that it will help. Doesn't that just impact the e-mails to registrants? How does that impact sign-in?

  • Options

    Did they get the emails when people registered?

    Have you tried it?

  • Options

    Going through the registration process as a new user is fine. You create your account, and the page refreshes. You also get an e-mail from "The Hive" (forum name) e-mail: info[at]hivejump[dot]com

    Registration works fine. It's literally just on sign-in on the home page. The home page fails to refresh and show you as logged in (also the bootstrap nav-bar doesn't update either). Finally, when I click the "The Hive" home button on the nav bar, it also fails to refresh.

    Also, this problem happens across multiple computers / users / browsers. So I think it has something to do with how my Vanilla is configured. I just don't know enough about Vanilla to know where it could be going wrong.

    If there were a quick way to just force a refresh, I would be satisfied, but I don't know how to do that either.

    Thanks for all the help, but I'm still lost for next-steps!

  • Options
    kamaleonkamaleon New
    edited June 2015

    From what I have seen in your installation, you have installed like 10000 addons :) and probably also modified some other 20000 files :)

    What I would do is a fresh install in a new location or over that one if you can, and try the basic things first before doing all the changes you have done...

  • Options

    That's not really an option for me at this point. Doesn't anyone have some knowledge as to the specific problem at hand? I'm not trying to be ungrateful for the help, but I can't spring for the nuclear option of re-installing everything due to time restrictions.

    I can also say that I've had this problem since I did the install (before I added addons and themes).

    I set up the Vanilla Forum via my GoDaddy backend, then upgraded to 2.1.0. It has to be something with the config files, or caching, or something NOT plugin or theme related!

  • Options
    BleistivtBleistivt Moderator

    This is most likely an addon issue. Disable all your plugin and see if it works.
    If it does, re-enable your plugins one by one and test the signin every time to find which one is causing the error.

  • Options

    I've disabled all plugins and chosen a clean theme. Doesn't change the issue one bit.

    We're chasing down the wrong rabbit hole. It definitely has something to do with my install settings somewhere. Some routing issue, cache issue, or something like that. I just don't know enough about Vanilla to know where to look!

  • Options

    I don't even care about solving the underlying issue really. If someone could just tell me how to force a page reload on sign-in, and when "The Hive" button is clicked, that would be ideal.

  • Options
    BleistivtBleistivt Moderator

    Well you can always set

    $Configuration['Garden']['SignIn']['Popup'] = false;
    

    Have you modified your .htaccess file or core files?

    I installed Vanilla via my GoDaddy hosting account, and then manually upgraded following all the steps listed in the Vanilla documentation.

    You never know what modifications automatic installers make.

    If you think it is a configuration issue, please post your config.php with all sensitive data (passwords, keys) blanked out.

  • Options
    hgtonighthgtonight ∞ · New MVP
    edited June 2015
    public function userModel_afterSignIn_handler($sender) {
        $entryController =& Gdn::Controller();
        $entryController->SetData('JustSignedIn', true);
        $entryController->Target('/');
    }
    
    public function entryController_render_before($sender) {
        if($sender->Data('JustSignedIn', false) === true) {
            Redirect();
        }
    }
    

    This is stupid, but it should work.

    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

    @hgtonight I will give this a shot. Where exactly does this code go?

  • Options
    hgtonighthgtonight ∞ · New MVP

    @mattdonatelli said:
    hgtonight I will give this a shot. Where exactly does this code go?

    Put it in your favorite plugin: http://docs.vanillaforums.com/developers/plugins/quickstart/

    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
    edited June 2015

    Here's my .htaccess file contents:

    # Modified
    # If you modify this file then change the above line to: # Modified
    <IfModule mod_rewrite.c>
       RewriteEngine On
       # Certain hosts may require the following line.
       # If vanilla is in a subfolder then you need to specify it after the /. 
       # (ex. You put Vanilla in /forum so change the next line to: RewriteBase /forum)
       RewriteBase /community/
       RewriteCond %{REQUEST_FILENAME} !-d
       RewriteCond %{REQUEST_FILENAME} !-f
       RewriteRule ^(.*)$ index.php\?p=$1 [QSA,L]
    </IfModule>
    
  • Options

    @hgtonight Sorry for my noobishness, but are you saying I should create my own plugin following the documentation at that link?

  • Options

    @hgtonight I downloaded and modified the Example plugin. Creating a new SignInRefresh plugin with your two functions as the only code in there (after setup code of course).

    Here's what happens when I hit sign-in.

    It's definitely having an effect, but isn't quite fully refreshing? Lots of visual errors near the bottom.

  • Options
    hgtonighthgtonight ∞ · New MVP

    Clone/download my testing ground: https://github.com/hgtonight/Plugin-TestingGround/archive/master.zip

    Paste that code into /plugins/TestingGround/class.testingground.plugin.php in the class definition.

    Enable it.

    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.

Sign In or Register to comment.