ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Ion Auth - Lightweight Auth System based on Redux Auth 2

February 10, 2010 7:00pm

Subscribe [287]
  • #901 / Apr 26, 2011 3:05pm

    jens.steppe

    5 posts

    Hi Ben,

    I’ve been searching an Authentication framework for my current project, and IonAuth looks very cool. I admire you for your support here.

    I have a project using CL 2 and Doctrine 2, can I easily intregrate your framework in my project?

    Cheers,

    J.

  • #902 / Apr 27, 2011 9:26am

    Johan André

    412 posts

    Hey!

    I used the spark-version (1.4) of Ion Auth. Is it possible to extend it with my own functions without changing the original file?

  • #903 / Apr 27, 2011 3:51pm

    jens.steppe

    5 posts

    Hi,

    I managed to get ion auth running, but i have a problem after logging in.

    My current project url has multiple virtual subdomain, test.mydomain.com and test2.mydomain.com point to the same as http://www.mydomain.com but test and test2 are to “users” of my project.

    But my problem is that the subdomains disappear after the login. I know that the login redirects to the baseurl that in my case is http://mydomain.com, but when i try to print the current subdomain before the login it is already gone.

    This is a problem because if users are on test.domain.com and they log in, i want to redirect back to test.domain.com and not to the homepage.

    Anyone has an idea?

    Thx

  • #904 / Apr 28, 2011 11:55pm

    Ben Edmunds

    812 posts

    ReyPM,

    The userguide is located at http://benedmunds.com/ion_auth/ but for something that complex you’re best just reading the code.

  • #905 / Apr 28, 2011 11:56pm

    Ben Edmunds

    812 posts

    Johan André,

    Not currently.  You could always extend the class though.

  • #906 / Apr 28, 2011 11:58pm

    Ben Edmunds

    812 posts

    jens.steppe,

    Just modify the controller to fit your needs.

  • #907 / Apr 29, 2011 3:23am

    jens.steppe

    5 posts

    I’m trying, but with not much succes so far 😊

    I’m having troubles setting it up to use my complete *.domain not only domain.com

    When i go to test.localhost/auth/index he redirects me to the login page, because im not logged in. I log myself in, he redirects me to the homepage localhost/home but when i try to go to test.localhost/auth/index he redirects me to the login screen again.

    I’ve tried to put the cookie domain to .localhost but this is not working so far.

    Anyone having same problems, or dealt with it in the past?

    Thx

  • #908 / May 01, 2011 11:01pm

    nomie7

    17 posts

    how can I get all active users in an array except the one logged in. I need to put user in a drop down list.

    I can get the list using get_active_users_array() but it includes the user who is logged in as well.

  • #909 / May 02, 2011 8:17pm

    Ben Edmunds

    812 posts

    nomie7,

    Something like this:

    $this->ion_auth->extra_where('users.id !=', $this->user->id);
    $users = $this->ion_auth->get_active_users_array();
    $this->ion_auth->extra_where('');
  • #910 / May 02, 2011 10:28pm

    nomie7

    17 posts

    Ben thanks for the help. Now is_logged_in() not working…

    <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
    
    class Messages extends CI_Controller {
        
            function __construct(){
            
            parent::__construct();
            $this->load->library('ion_auth');
            $this->load->library('session');
            $this->load->database();
            $this->load->helper('url');
        }
    
        
        function index(){
        
        if (!$this->ion_auth->logged_in())
            {
                $this->load->view('auth/index');
    
            } else {
                            $this->load->view('messages');
                    }
    }
    }

    Even if i am not logged in i get view of messages.

  • #911 / May 03, 2011 7:04pm

    Ben Edmunds

    812 posts

    nomie7,

    Check to see if the cookies are still there.  Test in different browsers.

  • #912 / May 04, 2011 2:26am

    nomie7

    17 posts

    I tried in different browsers still didnt work. I wrote the controller again and it works strange but oh well 😊

  • #913 / May 04, 2011 11:59am

    maxehhh

    3 posts

    Ben, i downloaded your ion_auth and when i try to use it localhost/index.php/auth y get the next error:

    A PHP Error was encountered

    Severity: Warning

    Message: Cannot modify header information - headers already sent by (output started at /Library/WebServer/ci/libraries/Exceptions.php:166)

    Filename: libraries/Session.php

    Line Number: 662

    A PHP Error was encountered

    Severity: Warning

    Message: Cannot modify header information - headers already sent by (output started at /Library/WebServer/ci/libraries/Exceptions.php:166)

    Filename: helpers/url_helper.php

    Line Number: 539

    I recently watched the newsletter tutorial from tutsplus and everything went fine, read about ?> and blank spaces but couldn’t find anything either. Can you please help me? 😊

  • #914 / May 04, 2011 12:01pm

    Ben Edmunds

    812 posts

    maxehhh,

    You could try turning on output buffering on your server.  If that fixes it then it is most likely whitespace somewhere.

  • #915 / May 04, 2011 12:10pm

    maxehhh

    3 posts

    You mean?

    $config[‘compress_output’] = FALSE;

    If it’s that i just changed it to TRUE but everything looks the same.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases