CodeIgniter Forums
DX Auth 1.0.6 (Authentication library) - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22)
+--- Thread: DX Auth 1.0.6 (Authentication library) (/showthread.php?tid=13644)



DX Auth 1.0.6 (Authentication library) - El Forum - 12-05-2008

[eluser]dexcell[/eluser]
It's updated to 1.0.2 now

Change log:

http://dexcell.shinsengumiteam.com/dx_auth/changelog.html

Upgrade

http://dexcell.shinsengumiteam.com/dx_auth/upgrade.html


DX Auth 1.0.6 (Authentication library) - El Forum - 12-05-2008

[eluser]Delete Me Please[/eluser]
Greetings,

Getting this error when trying to goto http://domain.com/auth/login:
Code:
A Database Error Occurred

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE `ip_address` = '127.0.0.1'' at line 2

SELECT 1 WHERE `ip_address` = '127.0.0.1'

I looked in the log file and the error is in the ./models/dx_auth/login_attempts.php file.

I used to use CL_Auth but I have removed it and tried to install yours. I'm pretty sure the old CL_Auth is not interfering, but I could be wrong. For more information, here is the total output of my log file when trying to access the login page:
Code:
DEBUG - 2008-12-06 09:06:37 --> Config Class Initialized
DEBUG - 2008-12-06 09:06:37 --> Hooks Class Initialized
DEBUG - 2008-12-06 09:06:37 --> URI Class Initialized
DEBUG - 2008-12-06 09:06:37 --> No URI present. Default controller set.
DEBUG - 2008-12-06 09:06:37 --> Router Class Initialized
DEBUG - 2008-12-06 09:06:37 --> Output Class Initialized
DEBUG - 2008-12-06 09:06:37 --> Input Class Initialized
DEBUG - 2008-12-06 09:06:37 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:37 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:37 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:37 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:37 --> Global POST and COOKIE data sanitized
DEBUG - 2008-12-06 09:06:37 --> Language Class Initialized
DEBUG - 2008-12-06 09:06:38 --> News Controller Initialized
DEBUG - 2008-12-06 09:06:38 --> Loader Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Helper loaded: url_helper
DEBUG - 2008-12-06 09:06:38 --> Helper loaded: form_helper
DEBUG - 2008-12-06 09:06:38 --> Helper loaded: html_helper
DEBUG - 2008-12-06 09:06:38 --> Database Driver Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Email Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Validation Class Initialized
DEBUG - 2008-12-06 09:06:38 --> DX Auth Initialized
DEBUG - 2008-12-06 09:06:38 --> Session Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Helper loaded: string_helper
DEBUG - 2008-12-06 09:06:38 --> Encrypt Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Session routines successfully run
DEBUG - 2008-12-06 09:06:38 --> Config file loaded: config/dx_auth.php
DEBUG - 2008-12-06 09:06:38 --> Language file loaded: language/english/dx_auth_lang.php
DEBUG - 2008-12-06 09:06:38 --> Config Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Hooks Class Initialized
DEBUG - 2008-12-06 09:06:38 --> URI Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Router Class Initialized
DEBUG - 2008-12-06 09:06:38 --> Output Class Initialized
DEBUG - 2008-12-06 09:06:39 --> Input Class Initialized
DEBUG - 2008-12-06 09:06:39 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:39 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:39 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:39 --> XSS Filtering completed
DEBUG - 2008-12-06 09:06:39 --> Global POST and COOKIE data sanitized
DEBUG - 2008-12-06 09:06:39 --> Language Class Initialized
DEBUG - 2008-12-06 09:06:39 --> Auth Controller Initialized
DEBUG - 2008-12-06 09:06:39 --> Loader Class Initialized
DEBUG - 2008-12-06 09:06:39 --> Helper loaded: url_helper
DEBUG - 2008-12-06 09:06:39 --> Helper loaded: form_helper
DEBUG - 2008-12-06 09:06:39 --> Helper loaded: html_helper
DEBUG - 2008-12-06 09:06:39 --> Database Driver Class Initialized
DEBUG - 2008-12-06 09:06:39 --> Email Class Initialized
DEBUG - 2008-12-06 09:06:39 --> Validation Class Initialized
DEBUG - 2008-12-06 09:06:39 --> DX Auth Initialized
DEBUG - 2008-12-06 09:06:39 --> Session Class Initialized
DEBUG - 2008-12-06 09:06:39 --> Helper loaded: string_helper
DEBUG - 2008-12-06 09:06:39 --> Encrypt Class Initialized
DEBUG - 2008-12-06 09:06:39 --> Session routines successfully run
DEBUG - 2008-12-06 09:06:39 --> Config file loaded: config/dx_auth.php
DEBUG - 2008-12-06 09:06:40 --> Language file loaded: language/english/dx_auth_lang.php
DEBUG - 2008-12-06 09:06:40 --> File loaded: ./models/dx_auth/login_attempts.php
DEBUG - 2008-12-06 09:06:40 --> Model Class Initialized
DEBUG - 2008-12-06 09:06:40 --> DB Transaction Failure
ERROR - 2008-12-06 09:06:40 --> Query error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE `ip_address` = '127.0.0.1'' at line 2
DEBUG - 2008-12-06 09:06:40 --> Language file loaded: language/english/db_lang.php



DX Auth 1.0.6 (Authentication library) - El Forum - 12-05-2008

[eluser]bugboy[/eluser]
I think you need to autoload the DX_auth config file for this


DX Auth 1.0.6 (Authentication library) - El Forum - 12-05-2008

[eluser]Delete Me Please[/eluser]
Fixed it.
No, it wasn't because of the autoload thing as described by bugboy. It was because I had MVC installed and that was messing with DX_Auth. Uninstalled and fixed Wink.


DX Auth 1.0.6 (Authentication library) - El Forum - 12-05-2008

[eluser]bugboy[/eluser]
i had that same error and auto loading the config file helped.

So there are two solutions to the same problem now which is great.

I've got it working with HMVC and Partial.

Have you got it working with MVC ( is that matchbox)


DX Auth 1.0.6 (Authentication library) - El Forum - 12-07-2008

[eluser]Johan André[/eluser]
Hey!

Thanks for a great library!
I have a question before using it in a current project though.

Is there any way to set URI permissions based on users instead of based on roles?

I have a situation where I got alot of sections (with separate admins and roles) and alot of bands assigned to each section. The bands will need access to their profile (but of course not the other bandprofiles).

Is this possible without making a group for each band?


DX Auth 1.0.6 (Authentication library) - El Forum - 12-08-2008

[eluser]tdktank59[/eluser]
[quote author="Johan André" date="1228698148"]Hey!

Thanks for a great library!
I have a question before using it in a current project though.

Is there any way to set URI permissions based on users instead of based on roles?

I have a situation where I got alot of sections (with separate admins and roles) and alot of bands assigned to each section. The bands will need access to their profile (but of course not the other bandprofiles).

Is this possible without making a group for each band?[/quote]

Some minor modifications sure...

Add another table and a few other small things you could do it based on user_id instead of group/role_id


DX Auth 1.0.6 (Authentication library) - El Forum - 12-08-2008

[eluser]uptown[/eluser]
I've installed the code, and I'm trying to load up one of the examples.
When I do, all I get is a partial login form. The last form element I see is the "Remember Me" label. In my server logs, I see an error:

[Mon Dec 08 16:50:35 2008] [error] [client 127.0.0.1] PHP Fatal error: Call to undefined function anchor() in C:\\server\\apache\\htdocs\\frameworks\\ci\\application\\views\\auth\\login_form.php on line 66

I've also attached a screenshot. Any ideas? This is running on my local installation of Apache on a Windows machine.


DX Auth 1.0.6 (Authentication library) - El Forum - 12-08-2008

[eluser]tdktank59[/eluser]
need to include url helpers....


DX Auth 1.0.6 (Authentication library) - El Forum - 12-08-2008

[eluser]uptown[/eluser]
[quote author="tdktank59" date="1228795352"]need to include url helpers....[/quote]

Yup ... that was it? Just curious ... why wouldn't that have been in the constructor of the controller already?