Post by nuchie11 » Fri Nov 19, 2021 8:15 am

How can I upload different fonts into OC 3.0?

Active Member

Posts

Joined
Tue Nov 28, 2017 11:13 pm

Post by moshair » Fri Nov 19, 2021 6:00 pm

Example to add Adelle-Regula font to default oc theme.

Method. 1
1. Use web fonts generator like https://transfonter.org/
2. Click add fonts and select Adelle_Reg.otf from your disk.
3. Download the generated fonts.
3. Upload web fonts (Adelle-Regular.woff, Adelle-Regular.woff2) to catalog\view\theme\default\stylesheet.
4. Add this code to catalog/view/theme/default/stylesheet/stylesheet.css in the top.

Code: Select all

@font-face {
    font-family: 'Adelle Rg';
    src: url('Adelle-Regular.woff2') format('woff2'),
        url('Adelle-Regular.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}
5. Now you have font family called'Adelle Rg'

in the 'catalog/view/theme/default/stylesheet/stylesheet.css' change

Code: Select all

body {
	font-family: 'Open Sans', sans-serif;
	font-weight: 400;
	color: #666;
	font-size: 12px;
	line-height: 20px;
	width: 100%;
}
to

Code: Select all

body {
	font-family: 'Adelle Rg', 'Open Sans', sans-serif;
	font-weight: 400;
	color: #666;
	font-size: 12px;
	line-height: 20px;
	width: 100%;
}

New member

Posts

Joined
Sun Jul 21, 2019 3:27 pm

Post by Rupesh Verma » Sat May 11, 2024 10:49 pm

Thanks for the guidefont generator @moshair. I'll try it.

Newbie

Posts

Joined
Fri Apr 14, 2023 8:53 pm


Post by paulfeakins » Mon May 13, 2024 6:47 pm

Rupesh Verma wrote:
Sat May 11, 2024 10:49 pm
Thanks for the guidefont generator @moshair. I'll try it.
If it works don't forget to add [S0LVED] to the start of this topic title.

UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk


User avatar
Legendary Member

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom
Who is online

Users browsing this forum: No registered users and 18 guests