Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Google Sign In with OpenID

Has error on redirect?

When I get elefant from composer, and visit the domain, it redirects to "/login", which isn't "{domain}/login". After I finish the installation, and when I login, it also redirects to "/user", which isn't "{domain}/user". It seems a bug.

Comments

  • Can you see if composer is downloading the newest files from Github? I'm wondering if it's getting an older version or if the issue is in the latest version.

  • I have tried to get it from composer, and download the zip file directly from github. Only I get this error? ... I tried in two different computer, this error came twice. :(

  • I just pushed a fix to the master branch on Github. I think that should fix it for you :)

  • Thanks. I find that when I install elefant, redirecting to "{domain}/install" is right. But when I login, it also redirect to "user", not "{domain}/user"

  • I just pushed another change to Github. Please let me know if it fixes it for you now. The reason was I started relying on a site_domain setting that not everyone has entered yet for their website.

    Now, it falls back on using the $_SERVER['HTTP_HOST'] value, but you can now set your domain name on the Administration > Site Settings page which is more secure.

  • edited September 2016

    After this change, I can't login the system now. When I click the login button, it redirect to "{domain}/login", which does nothing. It just stays there, and doesn't login at all. I also tried to change the config.ini file in admin app, set the domain there. It doesn't change.

  • That is odd. It should be sending you to /user/login. What is the path of the page you're logging in on? Have you tried logging in at /admin to see if that works?

  • It's all right now... That was odd, yes, and I don't know why. But now it is right :)

  • Seems another problem. When I click the save button in the site settings page, it fails with nothing output (I have turn on the "debug" and "display_errors")

  • The error message is bellow:

    ErrorException: strpos(): Empty needle

    strpos ("http://127.0.0.1/admin/settings", "")

    372D:\UPUPW_AP5.6\www\lib\Form.php

    1. */
    2. public function verify_referrer () {
    3. if (strpos ($_SERVER['HTTP_REFERER'], Appconf::admin ('Site Settings', 'site_domain')) === false && $_SERVER['HTTP_REFERER'] !== null) {
    4. return false;
    5. }
  • edited November 2016

    It seems cause another problem. I can't login system now :(

  • Oh no. Is there an error in your error logs?

  • Fatal error: Can't use function return value in write context in D:\soft\UPUPW_AP5.4\www\lib\Validator.php on line 179

  • I think this should fix it:

    https://github.com/jbroadway/elefant/commit/fe4cdfaa542aa380bb76f07d6f590cb7d19a3a43

    Please let me know if it still gives you problems.

  • Yes, it's right! Thanks a lot :)

  • Glad to hear! :)

Sign In or Register to comment.