1

I recently bought a template and I want to customize it.

I spoke with the help center and they said it's not necessary to use a child theme.

What is the best way to do that.

1 Answer 1

0

If the only changes you're making are CSS changes, you don't need to (but may still want to.) Keep a good backup of your CSS changes so you can reapply after a theme update.

If you're changing the actual template files, it may not be strictly necessary, but the best way is still to use a child theme. If you don't, it becomes a big headache to update your theme to the latest version in case of security/bug fixes, or feature enhancements. You update the theme, and lose your changes, so you have to apply your changes every time you update your theme. It becomes a headache, so you don't update, and can leave your ecommerce site open to security vulnerabilities.

Themes take up two areas on the site, app/design/frontend/themename (template files) and skin/frontend/themename (css, images, js, etc.). The theme's files are in themename/default, so copy any files you want to modify to themename/child and make your modifications there (and only the files you modify). Then in the Magento admin panel go to System -> Configuration -> General/Design. Make sure the current package is your new theme, and set all your themes to what you named your child theme.

Now you can modify away to your heart's content, without worry. Keep a good record of all your modifications (file path/name, line number of change, what the old code was and what the new code is), so that if a theme update fixes something in a file you changed, you can re-apply your changes to the fixed/updated theme file, otherwise you'll still be running that old code even when though you've updated the theme files.

1
  • Also consider putting //banu in your edits. I use //ckck in each file and at the top of each area I make changes. Later, it's very easy to find using grep -rin "banu" * Also write why you're doing it, I sure forget when looking back at it 2 years later.
    – Krista K
    Mar 23, 2016 at 14:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.