×

 

Home Contact Us Payments SC Commerce SC Commerce Docs SC Commerce Snippets

Simply Computing

We make websites. Simple.

Template Structure

SC Commerce template files contain the markup and template structure for frontend and HTML emails of your store.

When you open these files, you will notice they all contain hooks that allow you to add/move content without needing to edit template files themselves. This method protects against upgrade issues, as the template files can be left completely untouched.

Template files can be found within the /sc-commerce/templates/ directory.


Template Overrides via a Theme

You can edit these files in an upgrade-safe way using overrides. Copy the template into a directory within your theme named /woocommerce keeping the same file structure but removing the /templates/ subdirectory.

Example: To override the admin order notification, copy: wp-content/plugins/sc-commerce/templates/emails/admin-new-order.php to wp-content/themes/yourtheme/sc-commerce/emails/admin-new-order.php

The copied file will now override the SC Commerce default template file.

Warning: Do not edit these files within the core plugin itself as they are overwritten during the upgrade process and any customisations will be lost.

Note: There is a very slight chance that a core file may be modified in an upgrade. If this happens (and it is very unlikely) you will need to edit your override files accordingly. For more detailed information, see Fix Outdated Templates.


Template Overrides via a Plugin

It is also possible to place template overrides into a custom plugin.