Osclass Support Forums

Osclass theme support => Ideas, improvements and tips => Topic started by: Bikram Shakya on December 11, 2020, 12:49:49 PM

Title: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: Bikram Shakya on December 11, 2020, 12:49:49 PM
[11-Dec-2020 16:51:35 Asia/Kathmandu] PHP Warning:  count(): Parameter must be an array or an object that implements Countable in /home/hamronep/public_html/oc-includes/osclass/frm/Item.form.class.php on line 682
[11-Dec-2020 16:51:35 Asia/Kathmandu] PHP Warning:  Invalid argument supplied for foreach() in /home/hamronep/public_html/oc-includes/osclass/frm/Form.form.class.php on line 40
[11-Dec-2020 16:53:05 Asia/Kathmandu] PHP Warning:  Illegal string offset 'pk_i_id' in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 4
[11-Dec-2020 16:53:05 Asia/Kathmandu] PHP Warning:  Cannot assign an empty string to a string offset in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 4
[11-Dec-2020 16:53:05 Asia/Kathmandu] PHP Warning:  Illegal string offset 'pk_i_id' in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 13
[11-Dec-2020 16:53:05 Asia/Kathmandu] PHP Warning:  Illegal string offset 'pk_i_id' in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 124
[11-Dec-2020 16:53:26 Asia/Kathmandu] PHP Warning:  Cannot assign an empty string to a string offset in /home/hamronep/public_html/oc-includes/osclass/ItemActions.php on line 170
[11-Dec-2020 17:02:49 Asia/Kathmandu] PHP Warning:  Illegal string offset 'pk_i_id' in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 4
[11-Dec-2020 17:02:49 Asia/Kathmandu] PHP Warning:  Cannot assign an empty string to a string offset in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 4
[11-Dec-2020 17:02:49 Asia/Kathmandu] PHP Warning:  Illegal string offset 'pk_i_id' in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 13
[11-Dec-2020 17:02:49 Asia/Kathmandu] PHP Warning:  Illegal string offset 'pk_i_id' in /home/hamronep/public_html/oc-content/themes/realos/search-sidebar.php on line 124

Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: Bikram Shakya on December 11, 2020, 12:55:07 PM
So i revert back to 4.0
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: MB Themes on December 11, 2020, 12:55:58 PM
@Bikram Shakya
There is no error at all in your log.
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: Bikram Shakya on December 11, 2020, 12:59:04 PM
@Bikram Shakya
There is no error at all in your log.


 :-X :'(
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: MB Themes on December 11, 2020, 03:12:30 PM
I would guess you either have wrong version num in files or oc_t_admin table has not been properly updated.
You can even update it manually, there should be 3 new cols.

Code: [Select]
s_moderator_access VARCHAR(1000) NULL
i_login_fails INT(3) NULL DEFAULT 0
dt_login_fail_date DATETIME NULL

However, if everything is done in standard way, this will not be issue. You would recognize it in case you are logging as admin, but you cannot login and no error message is shown (in that case you know it failed to retrieve record from db due to different set of columns)
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: Bikram Shakya on December 12, 2020, 09:14:46 AM
I would guess you either have wrong version num in files or oc_t_admin table has not been properly updated.
You can even update it manually, there should be 3 new cols.

Code: [Select]
s_moderator_access VARCHAR(1000) NULL
i_login_fails INT(3) NULL DEFAULT 0
dt_login_fail_date DATETIME NULL

However, if everything is done in standard way, this will not be issue. You would recognize it in case you are logging as admin, but you cannot login and no error message is shown (in that case you know it failed to retrieve record from db due to different set of columns)


where to apply the code? :(
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: MB Themes on December 14, 2020, 10:43:06 AM
@Bikram
It's database structure.
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: Bikram Shakya on December 20, 2020, 12:18:30 PM
Can you tell me some more clue
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: Bikram Shakya on December 20, 2020, 12:29:48 PM
[20-Dec-2020 17:11:48 Asia/Kathmandu] PHP Warning:  count(): Parameter must be an array or an object that implements Countable in /home/hamronep/public_html/oc-includes/osclass/frm/Item.form.class.php on line 682
[20-Dec-2020 17:11:48 Asia/Kathmandu] PHP Warning:  Invalid argument supplied for foreach() in /home/hamronep/public_html/oc-includes/osclass/frm/Form.form.class.php on line 40
[20-Dec-2020 17:12:02 Asia/Kathmandu] PHP Warning:  count(): Parameter must be an array or an object that implements Countable in /home/hamronep/public_html/oc-includes/osclass/frm/Item.form.class.php on line 682
[20-Dec-2020 17:12:02 Asia/Kathmandu] PHP Warning:  Invalid argument supplied for foreach() in /home/hamronep/public_html/oc-includes/osclass/frm/Form.form.class.php on line 40
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: MB Themes on December 20, 2020, 01:20:50 PM
@Bikram
Thanks for feedback, both will be fixed in 4.2.2
Title: Re: After Upgrading 4.0 to 4.2.1 I couldnt able to login in oc-admin
Post by: Bikram Shakya on December 20, 2020, 02:24:43 PM
Ok sir :)