• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Problems with DB Session

#1
[eluser]Skinnpenal[/eluser]
Hi!

I'm trying out the Auth library, which utilizes DB Session.
When submitting the login form I get the error below.

Has any of you experienced this? How do I fix it? Smile

Thanks in advance!


A PHP Error was encountered
Severity: Notice
Message: Undefined index: user_agent
Filename: libraries/Db_session.php
Line Number: 297

A PHP Error was encountered
Severity: Notice
Message: Undefined index: ip_address
Filename: libraries/Db_session.php
Line Number: 298

A PHP Error was encountered
Severity: Notice
Message: Undefined index: session_id
Filename: libraries/Db_session.php
Line Number: 304

An Error Was Encountered
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 'SET last_activity = NULL, user_agent = NULL, ip_address = NULL, session_data = '' at line 1

UPDATE SET last_activity = NULL, user_agent = NULL, ip_address = NULL, session_data = 'a:1:{s:23:\"flash:newConfusedentry_status\";b:0;}' WHERE session_id

#2
[eluser]Crafter[/eluser]
Sound like you are configured to use database to store session values but your database table may not be created.
Revisit your session library manual pages on how to create the session table.

EDIT: Forget I said that. Fingers fater than brain! Sorry

#3
[eluser]esra[/eluser]
Auth has not been maintained for some time. There is a post somewhere on the forum that includes a link to the history of auth (auth, userauth, miniapp) and its different PHP4 and PHP5 implmentations that was written by peccavio.

FreakAuth is the most up-to-date ancestor of auth. The package includes a lot of sample code to get you started so don't let the number of files intimidate you. You only need a few of those files (userlib and its config file) to build your own implementation for your application.

EDIT: I recall seeing a recent post about auth written by a user that identifies some fixes for getting the original auth library to work under the 1.5.x series.

#4
[eluser]libnac[/eluser]
I have had this problem when I started application, but I solved this changing FALSE to TRUE in the line
$config['sess_use_database'] = TRUE;
of config.php.

#5
[eluser]Unknown[/eluser]
[quote author="libnac" date="1224190621"]I have had this problem when I started application, but I solved this changing FALSE to TRUE in the line
$config['sess_use_database'] = TRUE;
of config.php.[/quote]

this solved my problem - thanks


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


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