How to add my HTML theme to Aimeos Laravel Application

How to configure and adapt Aimeos based shops as developer
Forum rules
Always add your Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
aimeo.alpesh
Posts: 16
Joined: 26 May 2023, 05:24

How to add my HTML theme to Aimeos Laravel Application

Post by aimeo.alpesh » 26 May 2023, 05:59

I want to use my HTML theme to Aimeos Laravel Application.
What is the steps to use my own html template with Aimeos Laravel Application.
Specially how can i change html or view of body componetns.

My Aimeos Laravel Application configuration is as below :

aimeos-laravel : 2023.04.
Laravel Framework 10.11.0
PHP 8.2.2.

Many Thanks.

User avatar
aimeos
Administrator
Posts: 7858
Joined: 01 Jan 1970, 00:00

Re: How to add my HTML theme to Aimeos Laravel Application

Post by aimeos » 27 May 2023, 08:29

Please read this article, it contains all information for creating a new frontend theme:
https://aimeos.org/docs/latest/frontend ... te-themes/

Using own HTML templates is described here in detail:
https://aimeos.org/docs/latest/frontend ... templates/
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

aimeo.alpesh
Posts: 16
Joined: 26 May 2023, 05:24

Re: How to add my HTML theme to Aimeos Laravel Application

Post by aimeo.alpesh » 29 May 2023, 06:27

I have created extension ( Laravel theme 2023.x extension ) and unzip it in packages directory and processed below command.
composer req aimeos-themes/<mytheme>

There are two directories for templates to update component structures
1) packages/<mytheme>/templates/client/catalog/detail
2) vendor/aimeos-themes/<mytheme>/templates/client/catalog/detail

I have changed html structure in both places but not get my changes in home page.

Can you please help me and advice as i want to replace home page with my own theme home page.

Many Thanks

User avatar
aimeos
Administrator
Posts: 7858
Joined: 01 Jan 1970, 00:00

Re: How to add my HTML theme to Aimeos Laravel Application

Post by aimeos » 29 May 2023, 08:28

The vendor/aimeos-themes/<mytheme>/templates/client/catalog/detail/ directory usually is a link to packages/<mytheme>/templates/client/catalog/detail/ when using MacOS and Linux. If you are using Windows, you should change the files in the vendor/aimeos-themes/<mytheme>/templates/client/catalog/detail/ directory and copy them to packages/<mytheme>/templates/client/catalog/detail/ later when committing the files to Git.

To overwrite the catalog/home template, change this file(s):
- vendor/aimeos-themes/<mytheme>/templates/client/html/catalog/home/body.php resp.
- packages/<mytheme>//templates/client/html/catalog/home/body.php

Keep in mind, that the pages consists of different sections defined here:
https://github.com/aimeos/aimeos-larave ... op.php#L33

Furthermore, pages like the home page also contains CMS content from the CMS module in the admin backend which is the biggest part on the home page.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

aimeo.alpesh
Posts: 16
Joined: 26 May 2023, 05:24

Re: How to add my HTML theme to Aimeos Laravel Application

Post by aimeo.alpesh » 30 May 2023, 16:06

I have Linux ( Ubuntu 20.04) OS.
I have followed below steps to create my Aimeos Shop.

Steps :

1) Created shop by
composer create-project aimeos/aimeos myshop command.
2) Then created extension from https://aimeos.org/extensions/ with
Package Type : Aimeos 2023.x extension
3) Then i have unzipped downloaded zip to packages folder.
4) Then i have processed
composer req aimeos-extensions/<myextension> command.
5) Then I have copied whole vendor/aimeos/ai-client-html/templates/client/html derectory to
packages/<mytheme>/templates/client/
6) Then i have changed
packages/<mytheme>/templates/client/catalog/home/body.php file

Still not get my updated changes made to change fronted theme.

Please advice me if have missed any step or do anything wrong.

if posible provice me new steps and location where i have to change html.

Many Thanks.

User avatar
aimeos
Administrator
Posts: 7858
Joined: 01 Jan 1970, 00:00

Re: How to add my HTML theme to Aimeos Laravel Application

Post by aimeos » 30 May 2023, 16:57

Make sure you've disabled the content cache like described here:
- https://github.com/aimeos/aimeos-laravel#hints
- https://github.com/aimeos/aimeos/blob/m ... p.php#L196

Otherwise, you may have to delete the cache manually each time using:

Code: Select all

php artisan aimeos:clear
To disable caching for the basket too, use this setting:
https://github.com/aimeos/aimeos/blob/m ... p.php#L152
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

aimeo.alpesh
Posts: 16
Joined: 26 May 2023, 05:24

Re: How to add my HTML theme to Aimeos Laravel Application

Post by aimeo.alpesh » 01 Jun 2023, 11:22

Thank you for helping me. Every time manually delete the cache by given command is working fine for me and now I am getting my changes.

One more thing i didn't get and it's not updating.
In home three images component which is after slider component.
Below is the image screenshot link for what i am asking for.
https://ibb.co/dBbCChm

Want to update this component but not found it in my Aimeos 2023.x extension templates.

Many Thanks.

User avatar
aimeos
Administrator
Posts: 7858
Joined: 01 Jan 1970, 00:00

Re: How to add my HTML theme to Aimeos Laravel Application

Post by aimeos » 01 Jun 2023, 11:29

aimeo.alpesh wrote: 01 Jun 2023, 11:22 In home three images component which is after slider component.
Below is the image screenshot link for what i am asking for.
https://ibb.co/dBbCChm

Want to update this component but not found it in my Aimeos 2023.x extension templates.
This is already CMS content from the CMS module and stored in the database.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Post Reply