Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Application Path & Sign in problems

edited August 2005 in Vanilla 1.0 Help
I'm having a problem when users attempt to sign in. It appends the websites folder name at the end of the url... www.positivelyyoung.com/positivelyyoung when it should be just www.positivelyyoung.com ...if the user attempts to log in again it works with no error...I checked the application settings and the path to vanilla was incorrectly listed as www.positivelyyoung.com/positivelyyoung so I corrected the path but the application still attemps to take users to www.positivelyyoung.com/positivelyyoung when they sign in. Would this information be saved elsewhere?

Comments

  • it shouldn't be saved elsewhere. Are you the user that is trying to log in? It COULD be a cache issue, but I doubt it. Flush the cache and reload and let us know what happens. I will think of a few other possibilities in the mean time.
  • hey Nathan...I flushed the cache and tried to log in again and the same thing happened...I tried it on another computer of mine for the first time and it also happened. :|
  • well. Mmmmm.... Did you change the settings.php file through the admin interface (settings > appilication settings) or the file directly. If you can log in, I would suggest having a quick go through the admin interface and testing that. I have had a little trouble with editing file directly and having those changes take effect (more of an extension issue, but it could be related). get back to me on that one.
  • I made the change via the administration system...I also downloaded the settings.php file from the appg directory to verify the settings are correct...nothing appears to show the wrong URL.
  • MarkMark Vanilla Staff
    Where is your forum set up? Can we have a go at it?
  • the URL is www.positivelyyoung.com....sign up and you'll see what i mean...or you can log in with administrator/administrator
  • MarkMark Vanilla Staff
    edited August 2005
    Okay, can you create a test.php file and put this inside it:

    echo("PHP_SELF: " . $_SERVER["PHP_SELF"]); echo("<br />Directory: " . dirname($_SERVER["PHP_SELF"]));

    Then upload it to your server.
    Then view it in a web browser and tell me what it says...
  • Here is a copy of what the file showed. PHP_SELF: /positivelyyoung/test.php Directory: /positivelyyoung
  • MarkMark Vanilla Staff
    I've got to head out, but the problem is definitely to do with your server's use of PHP_SELF. If you take a look at controls/signin.php, you'll see that after you've been signed in, I rebuild the path to your discussion index:
    if ($AutoRedirect) {
    	if ($this->ReturnUrl == "") {
    		$this->ReturnUrl = dirname(ForceString(@$_SERVER["PHP_SELF"], ""));
    	} else {
    		$this->ReturnUrl = urldecode($this->ReturnUrl);
    	}							
    	$this->ReturnUrl = ForceString(@$_SERVER['HTTP_HOST'], "").$this->ReturnUrl;
    	header("location: http://".$this->ReturnUrl);
    	die();
    }
    On your server, the PHP_SELF *should* be something like "signin.php", but instead it is "positivelyyoung/signin.php".

    A quick fix for you would be to change this line:

    $this->ReturnUrl = ForceString(@$_SERVER['HTTP_HOST'], "").$this->ReturnUrl;

    to this:

    $this->ReturnUrl = ForceString(@$_SERVER["HTTP_HOST"], "");
  • thanks that worked!
  • MarkMark Vanilla Staff
    edited August 2005
    Nice :)
  • well I was no use then was I. Thanks for clearing that up Mark.
This discussion has been closed.