Jump to content

Archived

This topic is now archived and is closed to further replies.

Patrick73

Admin login loop after upgrade 2.3.3.1 to 2.3.3.2

Recommended Posts

The same! Harald we could debug it!

 

 

Warning: mysqli_real_escape_string() expects parameter 1 to be mysqli, null given in /web/oscom/v2332/includes/functions/database.php on line 129

 

Warning: mysqli_real_escape_string() expects parameter 1 to be mysqli, null given in /web/oscom/v2332/includes/functions/database.php on line 129

 

Warning: mysqli_query() expects parameter 1 to be mysqli, null given in /web/oscom/v2332/includes/functions/database.php on line 42

 

Warning: mysqli_errno() expects parameter 1 to be mysqli, null given in /web/oscom/v2332/includes/functions/database.php on line 42

 

Warning: mysqli_error() expects parameter 1 to be mysqli, null given in /web/oscom/v2332/includes/functions/database.php on line 42

-

 

INSERT INTO `usu_cache` (cache_name, cache_data, cache_date) VALUES ('', '', '2013-09-12 18:20:12')

 

[TEP STOP]


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

db_link is closed or lost. (null) Usu call final class Mysqli_Cache_Module implements iCache_System but it look like impossible to reach from core the db_link. The other cache systems (mysql, file, sqlite) work but only mysqli connection is lost.

 

I think this will be construction error. Nothing is reported only db_link is null.

 

The result is that nothing save to cache table. There are 3 url need to save into the cache but not done.


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

@@renzo.verschoor

 

I dont know your shop. My new installation is failed at client side too.


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

@@Gergely, this would tell me that it is not the cache issue....as;

a ) client side is working, this issue is only related to the admin side

b ) new installation, full package 2.3.3.2 is working on both sides

Share this post


Link to post
Share on other sites

@@renzo.verschoor

 

I used tep_db_connect() function where connection closed and problem is fixed. I dont know why is closed but PHP manual say that at the end of the script automatic closing every connections.


:blink:
osCommerce based shop owner with minimal design and focused on background works. When the less is more.
Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.

Share this post


Link to post
Share on other sites

@@Patrick, can you check the following for me......does your sessions.php located in 'admin/includes/functions' contains this code at line 102:

register_shutdown_function('session_write_close');

 

The full package has it, and mine current shop did not (also not the upgrade package).....when I added this line to sessions.php, all was working fine....

Share this post


Link to post
Share on other sites

@@Patrick, can you check the following for me......does your sessions.php located in 'admin/includes/functions' contains this code at line 102:

register_shutdown_function('session_write_close');

 

The full package has it, and mine current shop did not (also not the upgrade package).....when I added this line to sessions.php, all was working fine....

 

Right on!!!!

Seems I had missed the 2.3.3.1 update while on vacation. When I returned I seen the september 5 update but missed the august 27th one...

 

Everything is running and error messages are gone.

 

Thanks everyone !!!!

Share this post


Link to post
Share on other sites

I'm using Mindsparx admin, different from standard admin, so I have to do manual update. when updated, admin was complete out of work. The guide line may help others solve the problems.

 

The error_log recorded "oscommerce syntax error, unexpected $end login.php on line 194".

This was caused by missing "}" for line 26 in login.php: "if (tep_not_null($action)) {". Add "}" around line 112, the admin start semi work when using updated database.php. Work ok when use old database.php.

 

Find

$db = mysql_fetch_array(tep_db_query("select * from " . TABLE_MINDSPARX . " where id=1"));

 

around line 130 in login.php, change this line to

 

$db = mysqli_fetch_array(tep_db_query("select * from " . TABLE_MINDSPARX . " where id=1"));

 

Then update was successful !

Share this post


Link to post
Share on other sites

Hello, is this problem solved or not? If yes, how?

 

I wasn't sure if i should open a new thread or not... I have the same symptom (infinite redirects in admin login. Customer login works fine).

I have updated 2.3.3 -> 2.3.3.1 -> 2.3.3.2 -> 2.3.3.3. Login worked before 2.3.3.3.

I narrowed it down to application_top, where function function tep_session_is_registered is called but returns always false. So $redirect is always true...

 

The cookie is set, there's a session entry in the database without value (only sesskey). No entry at all in action recorder.

 

What else:

- checked if HTTP Auth data is same as admin login

- php version is 5.3.3

 

Thanks for any hint!

Share this post


Link to post
Share on other sites

My multi-zone multi-table shipment not work, install it and next click, the module would be appeared. I've to remove the multizone multitable configuration tables manually using phpadmin. Found the reason was caused by functions "mysql_XXXX_XXX" in mzmt.php, after those functions changed into "mysqli_XXXX_XXXX", the MZMT module is fully functional. Probaly search "mysql_" and change into "mysqli_" if any malfuction in your codes. May need an expert make compatibility change, I just don't know how to make that change.

Share this post


Link to post
Share on other sites

Hello, is this problem solved or not? If yes, how?

 

I wasn't sure if i should open a new thread or not... I have the same symptom (infinite redirects in admin login. Customer login works fine).

I have updated 2.3.3 -> 2.3.3.1 -> 2.3.3.2 -> 2.3.3.3. Login worked before 2.3.3.3.

I narrowed it down to application_top, where function function tep_session_is_registered is called but returns always false. So $redirect is always true...

 

The cookie is set, there's a session entry in the database without value (only sesskey). No entry at all in action recorder.

 

What else:

- checked if HTTP Auth data is same as admin login

- php version is 5.3.3

 

Thanks for any hint!

Find

$db = mysql_fetch_array

 

in login.php, change to

 

$db = mysqli_fetch_array

 

May solve your problem.

Share this post


Link to post
Share on other sites

Hi Patrick,

 

I also use the 'database.php' and 'general.php' of osc2.3.3.1 for the moment , untill i discovered the issue....

 

I have 'MySQL 5.5.32 Apache/2 php 5.3.27 (Zend: 2.3.0)', nevertheless, a new install of osc2.3.3.2 is working (full package) as I have testes that.....so it should be one add-on related error. or as stated by Jim we missed something by the upgrade (which I cannot believe)....

 

I also saw another post with this as solution

'Add-Ons that use the mysql_* or mysqli_* functions should use the tep_db_* functions instead. It's an easy update to perform and as Gary stated, conforms to the osCommerce standards'

The error was not related to ours, but I can update my add-ons to see if this works.....one payment add-on (client and admin side), called 'sisow', is using mysql_/myslqi_, so will change that to tep_db_

I have a sisow Add-On and I upgrade to 2.3.3.2

When checking out it gives an error

What is the solution for this

Share this post


Link to post
Share on other sites

×