Page 1 of 1
twig file modifications
Posted: Thu Aug 29, 2024 3:49 pm
by edkny
Hello,
I'm currently using OpenCart version 3.0.3.8 and made some modifications to my .twig files. However, after some time, I noticed that the changes reverted to the default versions. Could you please explain why this is happening and how I can ensure that my modifications are retained?
Re: twig file modifications
Posted: Thu Aug 29, 2024 4:03 pm
by by mona
How did you make the changes ?
Where did you make the changes ?
Have you checked the error logs to see if you installed an extension that conflicts with your changes ?
Are you using OCMOD and/or VQMOD together with the built in theme editor ?
Re: twig file modifications
Posted: Thu Aug 29, 2024 4:07 pm
by xxvirusxx
Make an ocmod file and don't use Twig editor from admin.
Re: twig file modifications
Posted: Thu Aug 29, 2024 4:50 pm
by edkny
Thank you for answers!
I added some css styles, but besides that I made changes in header.twig, menu.twig and more, I changed their posistions and more
can you advise me how I can make that kind of changes to stay
Re: twig file modifications
Posted: Thu Aug 29, 2024 5:25 pm
by by mona
by mona wrote: ↑Thu Aug 29, 2024 4:03 pm
How did you make the changes ?
ie
OCMOD
FTP
VQMOD
THEME EDITOR
by mona wrote: ↑Thu Aug 29, 2024 4:03 pm
Where did you make the changes ?
Maybe you made changes to the files in the modification folder?
by mona wrote: ↑Thu Aug 29, 2024 4:03 pm
Have you checked the error logs to see if you installed an extension that conflicts with your changes ?
?
by mona wrote: ↑Thu Aug 29, 2024 4:03 pm
Are you using OCMOD and/or VQMOD together with the built in theme editor ?
?
There is nothing wrong with OC3.0.3.8 - tell us what you have done and we can tell you how to do it right
Re css -
If your css is not "taking" you have not refreshed cache.
If it is "reverting" then you have a problem with an extension.
Re: twig file modifications
Posted: Thu Aug 29, 2024 6:27 pm
by edkny
I have made changes via theme editor
common/menu or common/header files
I haven't installed any extension yet
I don't quite understand this part
Are you using OCMOD and/or VQMOD together with the built in theme editor ?
I just edited the twig files in theme editor
maybe I should edit them in another directons
Thank you again for your reply
Re: twig file modifications
Posted: Thu Aug 29, 2024 6:51 pm
by by mona
There is an issue with using OCMOD together with the theme editor if you do not know what you are doing, but if you have no extensions installed and not using VQmod then it is strange.
Are the edits still in the theme editor?
Are you sure you have not reset the theme editor (ie that will clear your changes)
As virus said - the only other option is not to use it at all and learn how to write OCMODs, but moving stuff around is likely to be quite a big task for you.
1. Check your admin => extensions => installer
2. Check your admin => extension => modifications - In modifications there is a log tab.
3. Check both admin and root config.php are correct.
4. Check your theme settings correct in admin => systems => settings => edit settings page.
5. Delete theme cache via the settings icon on the top right of the dashboard.
You can also try
https://www.opencart.com/index.php?rout ... n_id=36203
Re: twig file modifications
Posted: Thu Aug 29, 2024 7:34 pm
by paulfeakins
edkny wrote: ↑Thu Aug 29, 2024 6:27 pm
I have made changes via theme editor
Never use that.
Re: twig file modifications
Posted: Thu Aug 29, 2024 8:15 pm
by JNeuhoff
Perhaps it might be a good idea to sort it out in the next OpenCart 3.0.x.x version, to make it all work together, using this order:
Theme editor
OCmod
VQmod
Re: twig file modifications
Posted: Fri Aug 30, 2024 10:32 pm
by paulfeakins
JNeuhoff wrote: ↑Thu Aug 29, 2024 8:15 pm
Perhaps it might be a good idea to sort it out in the next OpenCart 3.0.x.x version, to make it all work together, using this order:
Theme editor
OCmod
VQmod
Nah just remove the theme editor entirely from it.