Save / Export Preset Customisations

Hello,



How can I save or export my theme presets to a file?



We cloned basic theme, cloned Satori preset and then customised with our own colour scheme etc.



My reading seemed to suggest it should be saved to following location:



F:\example.com\htdocs\design\themes\mytheme\basic\data



F:\example.com\htdocs\design\themes\mytheme\presets\data



But I can't find any corresponding file, only the following:



ocean.json

satori.json

wooden.json



I would like to better understand how presets are saved and ensure our changes are safe before we put too much work in to completing customisations.



Advice appreciated.



Thanks, The Happy Fruit Bat

When you figure it out, please write a document and post it so that cs-cart can adopt it and provide information to others. The docs for V4 are just a bit weak at this point.

Has this ever been answered? I too am trying to figure this out as i want to have a solid back up before I upgrade…the presets seem to be saved in the database, but why is there not a json file like the default presets?



Jac

Well



in my expirience, you dont need any other files. Jyst the .css and .less. Every time you create a new preset with those two files (and maybe some images in …/media/images/preset_name) you can just transfer them in another Install or even use it in different stores in same CS-Cart



I ve done this with a very complicated store (1 main store 10 second stores) and all works this way, not having any problems at all.



My question is how do I use another Google Font, just like they did in Redish Skin. There is a few lines not clear enough .



/*GFONTS*/
@font-face {
font-family: 'PT Sans';
font-style: normal;
font-weight: 400;
src: local('PT Sans'), local('PTSans-Regular'), url(http://themes.googleusercontent.com/static/fonts/ptsans/v5/FUDHvzEKSJww3kCxuiAo2A.ttf) format('truetype');
}
/*/GFONTS*/


[color=#333333][font=Tahoma, Arial, Helvetica, sans-serif][size=3]This the Google Webfont-API use[/size][/font][/color], where can I find this?



Fotis



Well I found the answer by looking a little bit deeper than the 50 pages of Google Results on Google @font-face.



If you just put in you url this link http://fonts.googlea…amily=Open+Sans which is the source in the font you selected in Google fonts,


```php

Add this code to your website:


```

you get this result on the screen

```php
@font-face {
font-family: 'Open Sans';
font-style: normal;
font-weight: 400;
src: local('Open Sans'), local('OpenSans'), url(http://themes.googleusercontent.com/static/fonts/opensans/v6/cJZKeOuBrn4kERxqtaUH3T8E0i7KZn-EPnyo3HZu7kw.woff) format('woff');
}
```

So just copy the name of the Google font you need to use after the ?family= and just replace spaces with + sign

Fot example [url="http://fonts.googleapis.com/css?family=GFS+Neohellenic"]http://fonts.googlea...GFS+Neohellenic[/url]

```php
@font-face {
font-family: 'GFS Neohellenic';
font-style: normal;
font-weight: 400;
src: local('GFS Neohellenic Regular'), local('GFSNeohellenic-Regular'), url(http://themes.googleusercontent.com/static/fonts/gfsneohellenic/v4/B4xRqbn-tANVqVgamMsSDgBb2G5jwR1gaB5zdMT6AAg.woff) format('woff');
}
```

As for the script just put before src: the line subset: and you set like Greel, Latin etc.

Thats it

Hope this helps a little.

Thanks for the input and posting, hope that helps others too. I am still a little lost though, because even after I have created my new named and saved (and active) preset, there are no special copies of the a .css or .less file anywhere in the presets folder. I assume this is the place:



example.com\htdocs\design\themes\mytheme\presets\data



But all that is there is the same three json default files.



Where are the css and less files that you are referring to?



Jac

All the files are in



design/themes/basic/presets/data



Merry Christmas! Thanks for posting. I think that 4.0.2 and 4.0.3 versions do create the .css and .less files, I am in 4.0.1 and it does not save or create those files, it seems to store the preset data in a BLOB in the database. There is a table in the DB of 4.0.1 called cscart_theme_presets, that table is not in the newer versions.



My issue is that i really wanted to be able to save the presets as files as part of my back up as I am now preparing to upgrade to 4.0.3. Now I guess I just have to hope that the upgrade converts the database version of the presets to .less files.



Jac