Add-On For Theme Manager

Hello, so I wanted to add a hook using an add-on to the theme management page.

So I added a custom add-on

app/addons/advanced_addon/controllers/backend/themes.pre.php

That seemed to work. I could do PHP stuff in it.

Now, i wanted to add a view to this so following the advanced_addon tutorial here, i tried to put the view files in.

design/backend/templates/addons/advanced_addon/hooks/themes/manage.pre.tpl

And it didn't work.

Tried these as well:

design/backend/templates/addons/advanced_addon/hooks/themes/themes.pre.tpl
design/backend/templates/addons/advanced_addon/hooks/themes/manage/themes.pre.tpl
design/backend/templates/addons/advanced_addon/hooks/themes/manage/manage.pre.tpl

None of these seemed to work. Which is the correct location for my view? Please help.

Hello, so I wanted to add a hook using an add-on to the theme management page.

So I added a custom add-on

app/addons/advanced_addon/controllers/backend/themes.pre.php

That seemed to work. I could do PHP stuff in it.

Now, i wanted to add a view to this so following the advanced_addon tutorial here, i tried to put the view files in.

design/backend/templates/addons/advanced_addon/hooks/themes/manage.pre.tpl

And it didn't work.

Tried these as well:

design/backend/templates/addons/advanced_addon/hooks/themes/themes.pre.tpl
design/backend/templates/addons/advanced_addon/hooks/themes/manage/themes.pre.tpl
design/backend/templates/addons/advanced_addon/hooks/themes/manage/manage.pre.tpl

None of these seemed to work. Which is the correct location for my view? Please help.

There is no themes:manage hook. Please find the instructions on naming a hook in our Docs: http://docs.cs-cart.com/4.3.x/developer_guide/addons/hooking/tpl_hooks.html?

design/backend/templates/addons/advanced_addon/hooks/themes/tools_list.pre.tpl

  • {btn type="dialog" text=__("clone_theme_test") target_id="content_elm_clone_theme_`$theme_name`"}
  • check it will work.

    get hook like this:

    design/backend/templates/views/themes/manage.tpl

    {hook name="themes:tools_list"}
     
  • {btn type="dialog" text=__("clone_theme") target_id="content_elm_clone_theme_`$theme_name`"}
  • {/hook}

    Thanks will try that!

    Do you want to create new page or override existent one?

    Do you want to create new page or override existent one?

    Just wanted to add a hook. Figured it out already. Thanks!