Page 1 of 1

Overwriting core files??

Posted: Tue Jan 06, 2015 7:30 am
by dendr
Hello,

I'm entirely new to Opencart (current shop is Oscommerce) and I'm in the process of migrating.

I have a question regarding installation of extensions. All extension require me to put files in the catalog or admin folder.
But now I wonder, if I do this, don't the core files get overwritten?
Does this mean these extensions are not using VQ mod?
What would be the 'normal way' of installing an extension if it was using VQmod? I guess it would only update files in the VQmod folder, no?

So I'm trying to figure out whether I already ruined my files by overwrting them using these extensions.

thanks for the help.

Re: Overwriting core files??

Posted: Tue Jan 06, 2015 7:51 am
by rph
How exactly are you building your extensions? If you're using vQmod or OCMod those use cache files which don't affect the core.

Re: Overwriting core files??

Posted: Fri Jan 09, 2015 9:16 pm
by dendr
hello rph,

I just bought an extension. It contains the folder 'admin' and 'catalog'.
I transferred these by FTP to my Opencart site into the corresponding folders.
So now my question is?: did I overwrite the core files by doing this?

Because another extension required me to upload a .xml file into VQmod.

So seeing this new way of installing plugins by VQ mod I realized I might have overwritten the core files by simply transferring files by FTP.

So did I overwrite core files by transferring simply by FTp (as explained in te plugin modules)?

Re: Overwriting core files??

Posted: Sat Jan 10, 2015 4:46 am
by rph
It could have added new files withing OpenCart's structure. Were you prompted to overwrite any files? Are there installation instructions with the extension?

Re: Overwriting core files??

Posted: Sat Jan 10, 2015 6:10 am
by dendr
Well, the install instructions were easy: simply fut folder A and B in your root.

But this way I pollute my Opencart with files which difficult to be retrieved when a possible deinstall is desired.
Why do some plugin use these method?
I thought the power of Opencart resided in the fact that plugins do not touch the core files?

Or is this only valid for plugins which use VQmod?

Re: Overwriting core files??

Posted: Sat Jan 10, 2015 7:04 am
by rph
It's only valid if you're using vQmod or OCMod to change existing code. Adding entirely new sections is more complicated with no official guidance or best practices. For instance, routing and loading are hard coded to the application directory so developers are forced to put controller and model files in the /admin or /catalog directory.

Re: Overwriting core files??

Posted: Sat Jan 10, 2015 8:19 am
by fido-x
dendr wrote:I just bought an extension. It contains the folder 'admin' and 'catalog'.
I transferred these by FTP to my Opencart site into the corresponding folders.
So now my question is?: did I overwrite the core files by doing this?
No, you did not overwrite any core files. The files in the "admin" and "catalog" folders that you transferred are merged into the existing structure.
Because another extension required me to upload a .xml file into VQmod.
vQmod .xml files apply modifications to core files which are then cached. The cached files are then used instead of the original core files, which are left untouched.

Re: Overwriting core files??

Posted: Fri Oct 16, 2015 6:08 am
by Frescard
I'm in the same situation, and am a bit worried about overwriting core files.
I just installed opencart (V2.0.3.1), and downloaded this theme.
But it contains many files that already exist in other, non-theme related folders (e.g. layout_form.tpl in \admin\view\template\design). It also creates several new folders, that didn't exist in the default install (e.g. \admin\model\menu & \slider).
How do I ensure that I can go back to the pre-installation stage, once I overwrite all these files, and then want to go back? (And what happens if I install several themes, which may overwrite each others files?)

With other solutions that used themes (e.g. mediawiki) all theme-related files were always kept very separate from core files (so it was easy to go back and forth), but the file handling in opencart worries me a bit.