• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Redux Auth - is it dead?

i downloaded the most recent version from http://github.com/benedmunds/CodeIgniter-Ion-Auth

return (bool) $user_group == $admin_group;

isn't this casting the $user_group as bool? and not the complete $user_group == $admin_group?

When using:
return (bool)($user_group == $admin_group);
return (bool) $user_group == $admin_group;
it works like it should do.

But when using:
return (bool) $user_group == $admin_group;
every group is returning true

[eluser]Phil Sturgeon[/eluser]
Yes you are totally right, I was being an idiot. It was comparing TRUE to 'whatevergroup' which in PHP will return TRUE. It has been removed. Sorry for that very, very stupid mistake.

Sorry if this is a bit daft, but, what's the default admin password for Ion Auth? Thought it would be in the config file, but it isn't.

it is
user: [email protected]
pass: password


what is the reason for using two tables like users and meta rather than one single users-table?

Best regards

[quote author="joytopia" date="1265217276"]Thank you, 2think,
now I got it running. At the first glance it looks very well.

One question:

normally a controller starts like this:

class Test extends Controller {

    function Test()

but the controller in Ion Auth starts like that:

class Auth extends Controller {

    function __construct()

What is the difference, and how do I have to deal with it?

Thanks and best regards,

It's the same thing.
PHP 5 uses the construct function as __construct() where you used to have the class name. So if no __construct() is found PHP will search for ClassName() instead.
I read this in a recent PHP 5.3 book and they recommend you to use __construct() and __destruct(). (And to be honest it looks better this way! it's easier to see them)

For more information:

2think, Queops,
thanks for your answers! Somewhere I read, that CI 2.0 will be php 5 only.

I saw, that you have transactions in the model. So I should better change my tables to innoDB?

Since we will have a lot of user generated content in our project, innoDB will be the better choice in general?

Thanks and best regards

[quote author="klompie" date="1265476407"]it is
user: [email protected]
pass: password[/quote]

Thank you!

[quote author="joytopia" date="1265581167"]Phil,

what is the reason for using two tables like users and meta rather than one single users-table?

Best regards


I think the use of the two tables allows the developer to extend details about a user should they need it, for example, future roles support, shipping address, whatever else. At least that is my assumption, don't know for sure.

2think, thank you!

There also could be some more good reasons to have two separate tables:
- Database performance: When users edit their profile, they only work in the meta-table,
- an existing user-table can be used as meta-table without any changes.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.