Post by pablitoesco84 » Sat Oct 01, 2022 10:28 pm

First of all, I am NOT asking for step by step detailed processes. (using OpenCcart 4.0.1.1)

I am just asking for a general advice how to do it.

#############################################
#############################################

So far I have created a custom theme.

And I can modify my HEADER inside the file below.

FILE: public_html/extension/customtheme/catalog/view/template/common/header.twig

#############################################
#############################################

My question is, how can I create a twig file to customize my own menu HTML markup?

I was thinking by creating "menu.twig" and put it inside the "common" folder like below.

FILE: public_html/extension/customtheme/catalog/view/template/common/menu.twig

But it is not working.

Or at least I cannot see changes inside the front end.

Any general idea how to do this properly?

Newbie

Posts

Joined
Wed Jul 13, 2022 1:18 am

Post by pablitoesco84 » Tue Oct 04, 2022 12:42 am

THIS POST IS SOLVED

The only issue was adding the names inside controllers.

In my case these two controllers below.

public_html/extension/my_custom_theme/admin/controller/theme/custadobe.php

public_html/oc4/extension/my_custom_theme/catalog/controller/startup/custadobe.php

For instance if I had the code below and I wanted to change the footer, I had to add footer.

Code: Select all

 public function event(string &$route, array &$args, mixed &$output): void
    {
        $override = [
            'common/header',
            'common/menu',
        ];
Like this below.

Code: Select all

 public function event(string &$route, array &$args, mixed &$output): void
    {
        $override = [
            'common/header',
            'common/menu',
            'common/footer',
        ];

Newbie

Posts

Joined
Wed Jul 13, 2022 1:18 am
Who is online

Users browsing this forum: No registered users and 12 guests