DB explanation - mshop_media

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)
lucadambros
Posts: 44
Joined: 24 Jun 2019, 14:46

DB explanation - mshop_media

Post by lucadambros » 09 Oct 2019, 10:27

Hi,
I need to know more about the mshop_media table. The field "preview" is quite hard to understand for me.

How that work?

I have raw data and I want to insert it into that table (links for image products). How the json is created?
I mean, why sometimes you start with

Code: Select all

{"1": ...

and other times you start with

Code: Select all

{"240": ...
?

Thank you very much

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

Re: DB explanation - mshop_media

Post by aimeos » 09 Oct 2019, 11:43

The JSON in the "preview" column represents the different preview image sizes with the width of the image in px as key (e.g. "240"). If an image doesn't has a size (e.g. SVG) or isn't an image, than "1" px width is used as key.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

lucadambros
Posts: 44
Joined: 24 Jun 2019, 14:46

Re: DB explanation - mshop_media

Post by lucadambros » 09 Oct 2019, 11:52

Thank you very much! :D

Post Reply