Page 1 of 1

[SOLVED] - Cannot open admin page / ERror Message on website.

Posted: Mon May 20, 2019 6:47 pm
by Pretty Girl
Guys / Gals

I didn't notice when this started, but it was reported by a prospective customer, but on my website i get

Code: Select all

Warning: "continue 2" targeting switch is equivalent to "break 2". Did you mean to use "continue 3"? in /home/puzzlepi/prettygirlwear.co.uk/vqmod/vqmod.php on line 591
Warning: Cannot modify header information - headers already sent by (output started at /home/puzzlepi/prettygirlwear.co.uk/vqmod/vqmod.php:591) in /home/puzzlepi/prettygirlwear.co.uk/system/framework.php on line 108Warning: Cannot modify header information - headers already sent by (output started at /home/puzzlepi/prettygirlwear.co.uk/vqmod/vqmod.php:591) in /home/puzzlepi/prettygirlwear.co.uk/catalog/controller/startup/session.php on line 25

On admin login i get the message below and it wont allow me to log in

Code: Select all

Warning: "continue 2" targeting switch is equivalent to "break 2". Did you mean to use "continue 3"? in /home/puzzlepi/prettygirlwear.co.uk/vqmod/vqmod.php on line 591
Warning: Cannot modify header information - headers already sent by (output started at /home/puzzlepi/prettygirlwear.co.uk/vqmod/vqmod.php:591) in /home/puzzlepi/prettygirlwear.co.uk/system/framework.php on line 108
I have copied the lines around 591 (starting 585 > 601 if this helps at all )

Code: Select all

if($mod['search']->regex == 'true') {
						$pos = @preg_match($mod['search']->getContent(), $line);
						if($pos === false) {
							if($mod['error'] == 'log' || $mod['error'] == 'abort' ) {
								VQMod::$log->write('VQModObject::applyMod - INVALID REGEX ERROR - ' . $mod['search']->getContent(), $this);
							}
							continue 2;
						} elseif($pos == 0) {
							$pos = false;
						}
					} else {
						$pos = strpos($line, $mod['search']->getContent());
					}

					if($pos !== false) {
						$indexCount++;
						$changed = true;


Any help would be appreciated.

Re: Cannot open admin page / ERror Message on website.

Posted: Mon May 20, 2019 11:28 pm
by uksitebuilder
It is more likely that one of your vqmod files is the culprit and vqmod.php is having a hard time interpreting it.

I first suggest you simply clear out your vqmod/vqcache folder and delete vqmod/mods.cache and vqmod/checked.cache files

Then try

If problem persists, repeat the above and disable all vqmod/xml files by renaming them and appending .bak to their filename (apart from vqmo.xml which is required by vqmod itself).

Then try to access your admin.

If all is well, you can enable each renamed xml file by removing the .bak extension and test after each one.

Eventually you will hit the error again and will then know the last file you enabled is the culprit.

Re: Cannot open admin page / ERror Message on website.

Posted: Tue May 21, 2019 4:47 am
by Pretty Girl
uksitebuilder wrote:
Mon May 20, 2019 11:28 pm
It is more likely that one of your vqmod files is the culprit and vqmod.php is having a hard time interpreting it.

I first suggest you simply clear out your vqmod/vqcache folder and delete vqmod/mods.cache and vqmod/checked.cache files

Then try

If problem persists, repeat the above and disable all vqmod/xml files by renaming them and appending .bak to their filename (apart from vqmo.xml which is required by vqmod itself).

Then try to access your admin.

If all is well, you can enable each renamed xml file by removing the .bak extension and test after each one.

Eventually you will hit the error again and will then know the last file you enabled is the culprit.
Thank you for your response, and unfortunatly it didn't work, which pushed me to try a few new things, and it turns out it was simply the VQMod needing updateing
Due to the change
"Changed continue 2; to break 2 to satisfy php 7.3 warning"

This is all that caused me problem :( but thanks for your response. #

Finally for others who might have similar problem https://github.com/vqmod/vqmod/releases is a link to their latest version :D

thanks

PG

Re: Cannot open admin page / ERror Message on website.

Posted: Fri May 29, 2020 9:57 pm
by teuscher1
uksitebuilder wrote:
Mon May 20, 2019 11:28 pm
It is more likely that one of your vqmod files is the culprit and vqmod.php is having a hard time interpreting it.

I first suggest you simply clear out your vqmod/vqcache folder and delete vqmod/mods.cache and vqmod/checked.cache files

Then try

If problem persists, repeat the above and disable all vqmod/xml files by renaming them and appending .bak to their filename (apart from vqmo.xml which is required by vqmod itself).

Then try to access your admin.

If all is well, you can enable each renamed xml file by removing the .bak extension and test after each one.

Eventually you will hit the error again and will then know the last file you enabled is the culprit.
Hi there
I have the same problem :( but no errors and the login page is on a loop
I tried your suggestion above and many others I have found but nothing seem to work unfortunately.

Running on 1.5.6.4
https://cmente.com/tienda/admin/
A week ago I asked my service provider to install ssl but the problem to log in was there before. I haven't been able to set my opencart shop to SSL given that I cant access the admin.
I have a number of vqmodes but none of them are the problem after following your suggestions
Service provider reported me a number of errors on server side but I fix them all after installing the new version of vqmode and changing the php version

Can I ask you what info can I provide to identify where the problem could be?

Thanks in advance

Re: Cannot open admin page / ERror Message on website.

Posted: Fri May 29, 2020 11:22 pm
by straightlight
Running on 1.5.6.4
Posting in the v3.x releases section of the forum.

Re: Cannot open admin page / ERror Message on website.

Posted: Fri May 29, 2020 11:53 pm
by teuscher1
Sorry about this :/

I will list a new post on that forum

Re: Cannot open admin page / ERror Message on website.

Posted: Sat May 30, 2020 1:28 am
by xxvirusxx
Check admin config to see if you have all changed to :https

Re: Cannot open admin page / ERror Message on website.

Posted: Sat May 30, 2020 1:02 pm
by teuscher1
Hi xxvirusxx

My access to admin is working now, many thanks for your smart suggestion.

This is what I did for other to see:

In /admin/config.php I have also changed the "//HTTP" to "https" and it is working now, I cant believe I missed that before.

Code: Select all

// HTTP
define('HTTP_SERVER', 'https://website.com/admin/');
define('HTTP_CATALOG', 'https://website.com/');

// HTTPS
define('HTTPS_SERVER', 'https://website.com/admin/');
define('HTTPS_CATALOG', 'https://website.com/');
Also a good night sleep helps to clear the mind after trying many solutions the day before.

good luck! ;)

teuscher1