Prestashop how to customize theme - prestashop

I have bought leo_chopin theme (because client asked for it). My question is how to customize a theme from html/php/css editor and not from admin panel (it's too constricting). I wouldn't hardcode, but use hooks. This is the first time I'm using Prestashop and that style of programing... For example, where to call my own header.tpl, footer.tpl, content.tpl?
Thank you in advance for your help.

Go to your_site_folder/themes/leo_chopin/ and you will find header.tpl, footer.tpl.
You can modify these templates there or make a copy of a theme into another folder and modify it.
All content between header and footer depends on a page controller. All controllers for the front are in a folder your_site_folder/controllers/front/. ProductController.php is for product pages, CategoryController.php is for category pages, IndexController.php is for the home page etc.
You can find more in Prestashop documentation: http://doc.prestashop.com/display/PS16/Laying+the+Theme's+Foundations.

Related

Prestashop template extends in child theme

I'm beginning to use PrestaShop so I've installed a 1.7.7.1 with the classic theme.
I have created a child theme which uses the classic theme as parent and selected it through the admin page. The website shows normally.
When creating a child theme, I'm trying to modify a small part of the product page by creating a product.tpl page in the child theme. I then try to extends the parent product page but this doesn't work, the product page just stays blank.
Here is the line in my child-theme/template/catalog/product.tpl file:
{extends file='parent:catalog/product.tpl'}
Doing so, I should see the product page as it is with the classic theme.
I've watched some tutorials and I've done the exacts same steps and it is not working properly for me. I can't figure out what I did wrong.
Thanks for the help !
Ok, that was easy, I solved my problem by deactivating the cache and choosing "Recompile templates if the files have been updated" in the advanced parameters.

WHMCS - Editing purchased theme by overriding specific files

I want to customize the purchased WHMCS theme but I don't want to loose the changes when the theme is updated.
So, is there a way to create a child type of theme just like we do on Wordpress. If not, please advice the best method to do it in WHMCS.
WHMCS doesn't support clientarea template files overriding as in WP.
Use git to follow changes in the original purchased template, as described in Six template page

Customize Hybris Backoffice login Theme

Anyone has an idea about how to change the default Backoffice Login Theme (Color, Background and image or any of these) ?
It could be helpful if you point out the file(s) responsible for this, or a specific way to customize it.
Using Hybris 6.0 or later.
Replacing Styles of Backoffice Application :
It is possible to replace the standard look and feel of the Backoffice Application. In other words, you can change the style sheet used in login page and main application pages including all components.
Files responsible for changing Backoffice main page style are located in the following key properties :
backoffice.cockpitng.mainpage.css=/cng/css/mainpage_whitelabel.css
backoffice.cockpitng.loginpage.css=/cng/css/loginpage_whitelabel.css
backoffice.cockpitng.overridewidgetsandeditors.css=/cng/css/customWidgetsAndEditors.css
For more about this topic, you can visit this link.

How to edit prestashop back office product listing page

I want to change the layout of prestashop back office product page.
So can anyone tell me which file to change so that I can modify this existing layout?
I don't know which page you want to edit exactly, but when you go to that page in your backoffice, like:
http://www.example.com/admin123/index.php?tab=AdminAttributesGroups
The admin123 is variable to your installation, but the ?tab=AdminAttributesGroups referes to the backoffice page you are on. These pages are located in /var/www/admin123/tabs in this case it's /var/www/admin123/tabs/AdminAttributesGroups.php
I found the solution.... Here is what I did
Added content.tpl in under adminxxyy/theme/theme_name/template/controller/products
Which showed me content of my content.tpl
Create a new module, register the hook and send that info via hook to content.tpl.
Use hook name in content.tpl like {hook h='displayProductMyWay' mod='blockcustom'}.

Shopify "test" template page

Is there any way to publish a test template page? For example, if I have a template file called "cart-test.liquid," is there anything I can modify so I can navigate to "http://shopname.com/cart-test" in order to test it out?
I'm currently developing an widget that'll be included on Shopify cart pages, and one of my clients wants to test it out before it's published on their real cart page.
The best way to test a theme without editing the live theme is to duplicate the current theme and use the preview function.
From within the Shopify admin (using Shopify Admin 2) goto the "Themes" section. Here you can "duplicate" the published main theme. It will create a copy of the theme within the "Unpublished themes" section. Here you can edit it and also get a preview of this theme (click on the link preview).