X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (X-Cart 5) (https://forum.x-cart.com/forumdisplay.php?f=56)
-   -   Change Font of Standard Template (https://forum.x-cart.com/showthread.php?t=76710)

rubendn 12-18-2018 10:59 AM

Change Font of Standard Template
 
Is it possible to change the font used in the Standard template to a Google Font?

I don't think you can use @import under Custom CSS & JS.

This is what I added:

@import url('https://fonts.googleapis.com/css?family=Lato');

body, .navbar-nav, .head-h2, .head-h3, .sidebar {
font-family: 'Lato', sans-serif;
}

cflsystems 12-18-2018 02:01 PM

Re: Change Font of Standard Template
 
I would create simple module, decorate View/CommonResources class

protected function getCommonFiles()

XC loads there "Open Sans" font from Google fonts and you can remove it and add Lato.
This has to be done with custom module - don't just modify the XC file.

You may need to modify some css files as well and replace every reference to "Open Sans" with "Lato"

OR you can also try with @font-face as this will create an alias for the "Open Sans"

@font-face {
font-family: "Open Sans";
src: url(/local/path/to/Lato);
}


All times are GMT -8. The time now is 10:39 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.