Post by SubatWest » Mon Jan 30, 2023 5:12 pm

Using OC 3.0.3.8 upgraded to run under PHP 8
Have developed the site on localhost where it runs perfectly on both front and admin.
Migrated to live site the front end runs perfectly.
The admin site runs everywhere as normal, except for the modifications page, which does not show. Only a full white page shows.
The link on the live site is:
"https://**********.com/admin/index.php?route=marketplace/modification&user_token=HVOk8iduPo4vUpovYiEnutdj3J6Lq5iZ"

One error is reported in the logs:
"2023-01-29 21:35:00 - PHP Warning: Attempt to read property "textContent" on null in /home/*******/public_html/storage/modification/admin/controller/marketplace/modification.php on line 160"

Have refreshed storage etc. but problem remains.
Have checked config file which reads:

Code: Select all

define('DIR_APPLICATION', '/home/********/public_html/admin/');
define('DIR_SYSTEM', '/home/*******/public_html/system/');
define('DIR_IMAGE', '/home/******/public_html/image/');
define('DIR_STORAGE', '/home/******/public_html/storage/');
define('DIR_CATALOG', '/home/******/public_html/catalog/');
define('DIR_LANGUAGE', DIR_APPLICATION . 'language/');
define('DIR_TEMPLATE', DIR_APPLICATION . 'view/template/');
define('DIR_CONFIG', DIR_SYSTEM . 'config/');
define('DIR_CACHE', DIR_STORAGE . 'cache/');
define('DIR_DOWNLOAD', DIR_STORAGE . 'download/');
define('DIR_LOGS', DIR_STORAGE . 'logs/');
define('DIR_MODIFICATION', DIR_STORAGE . 'modification/');
define('DIR_SESSION', DIR_STORAGE . 'session/');
define('DIR_UPLOAD', DIR_STORAGE . 'upload/');
Have tried to spot what is going on but cannot see the issue that causes the problem. Can anyone cast an eye over this and suggest what might be the problem?
Thank you.
Last edited by SubatWest on Wed Feb 01, 2023 8:09 pm, edited 1 time in total.

Active Member

Posts

Joined
Fri Oct 31, 2014 1:29 am

Post by xxvirusxx » Mon Jan 30, 2023 5:18 pm

SubatWest wrote:
Mon Jan 30, 2023 5:12 pm
/storage/modification/admin/controller/marketplace/modification.php on line 160"
What ocmod extension you have installed?

Upgrade Service | OC 2.3.0.2 PHP 8 | My Custom OC 3.0.3.8 | Buy me a beer


User avatar
Expert Member

Posts

Joined
Tue Jul 17, 2012 10:35 pm
Location - România

Post by JNeuhoff » Mon Jan 30, 2023 5:44 pm

OpenCart 3.0.3.8 doesn't work on PHP 8, use PHP 7.4.

Also, are you using the Integrated VQMod extension by any chance?

Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig


User avatar
Guru Member
Online

Posts

Joined
Wed Dec 05, 2007 3:38 am


Post by SubatWest » Mon Jan 30, 2023 7:49 pm

xxvirusxx I have installed a number of extensions. It is the strangeness of working on localhost with all the same extensions but nt live,

Active Member

Posts

Joined
Fri Oct 31, 2014 1:29 am

Post by SubatWest » Mon Jan 30, 2023 7:53 pm

JNeuhoff I do not use Vqmod and have an xml locatd in the folder public_html\system that redirects:
Its code is:

Code: Select all

?xml version="1.0" encoding="UTF-8"?>
<modification>
    <id>VQMOD CORE FOR OPENCART - DO NOT REMOVE</id>
    <version>1.4.x and above</version>
    <vqmver required="true">2.6.0</vqmver>
    <author>vqmod.com</author>

    <file name="system/startup.php,system/engine/*.php,system/library/*.php,admin/controller/extension/*.php,system/library/template/*.php,catalog/controller/event/theme.php,system/library/template/Twig/*.php" error="skip">
        <operation error="skip" info="For non OCMod includes/requires">
            <search regex="true"><![CDATA[~^(\s*)(require|include)(_once)?(\s+|\()(?!VQMod::modCheck\()(?!modification\()([^);]+)~]]></search>
            <add position="replace"><![CDATA[$1$2$3$4\\VQMod::modCheck($5)]]></add>
        </operation>
        <operation error="skip" info="For OCMod includes/requires - OPERATION MUST BE AFTER NON OCMOD INCLUDES/REQUIRES OPERATION">
            <search  regex="true"><![CDATA[~(require|include)(_once)?\((?!VQMod::modCheck\()modification\(([^)]+)~]]></search>
            <add position="replace" ><![CDATA[$1$2(\\VQMod::modCheck(modification($3), $3]]></add>
        </operation>
	</file>

    <file name="system/library/template/Twig/*.php" error="skip">
	    <operation error="skip" info="Add Twig support">
            <search ><![CDATA[dirname(__FILE__).'/../']]></search>
            <add position="replace"><![CDATA[DIR_SYSTEM . 'library/template/']]></add>
        </operation>
    </file>

    <file name="system/library/template/Twig/Loader/*.php" error="skip">
	    <operation error="skip" info="Add Twig support">
            <search ><![CDATA[= $realpath;]]></search>
            <add position="replace"><![CDATA[= VQMod::modCheck($realpath, DIR_TEMPLATE . $name);]]></add>
        </operation>
    </file>

</modification>

Active Member

Posts

Joined
Fri Oct 31, 2014 1:29 am

Post by JNeuhoff » Mon Jan 30, 2023 8:32 pm

If you don't have VQmod then why do you even have this XML file in there?

And it looks like one of your OCmod extensions modifies the admin/controller/marketplace/modification.php, which is a bad thing to do.

But the actual error is caused by one of your OCmod-based extensions using an XML with a missing <name>...</name> tag.

Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig


User avatar
Guru Member
Online

Posts

Joined
Wed Dec 05, 2007 3:38 am


Post by SubatWest » Mon Jan 30, 2023 9:45 pm

Thanks will check this out.

Active Member

Posts

Joined
Fri Oct 31, 2014 1:29 am

Post by SubatWest » Mon Jan 30, 2023 10:13 pm

Have checked this out. All xmls have name tag, I am still puzzled as to why localhost and live have exactly the same files and file sructure and yet there is this issue?

Active Member

Posts

Joined
Fri Oct 31, 2014 1:29 am

Post by SohBH » Tue Jan 31, 2023 8:08 pm

Your javascript is misplaced before DOM is ready.

Business Web Development | Content Creation | Analytics and Reporting | SEO


User avatar
Active Member
Online

Posts

Joined
Mon Nov 02, 2020 12:01 am
Location - Malaysia

Post by SubatWest » Wed Feb 01, 2023 8:11 pm

The problem was in the storage of log files.
ocmod.log was deleted from storage logs and the matter was resolved.

Active Member

Posts

Joined
Fri Oct 31, 2014 1:29 am
Who is online

Users browsing this forum: DesignCart and 97 guests