Post by ventienda » Thu Oct 22, 2015 8:45 am

Hola a Todos!

Uso OC 1.5.6.4 y un template.

Mi idea es aplicar la misma fuente en sus dos estilo: Regular y Italic. Se llama LibreBaskerville-Regular.ttf y LibreBaskerville-Italic.ttf.

Italic para el texto del cuerpo mientras Regular para los títulos y el footer con tamaños a convenir.

Lo que hice fue:
1) Subir los archivos .ttf al servidor en... catalog/view/them/MI_PLANTILLA/stylesheet

2) Agregué en la 1° línea del stylesheet.ccs...

Code: Select all

@font-face {
     font-family: ´Libre Baskerville´;
     scr: url (´LibreBaskerville-Italic.ttf´)
     font-weight: normal;
     font-style: normal;
}      
RESULTADO:

Todo el contenido (Header, body, footer) cambió el tipo de letra Italic, pero después de refrescar con F5 y Control F5 Sólo puede ver la fuente con Internet Explorer, pero no con los demás browser.

PREGUNTA:

A) Cómo logró unificar el cambio?
B) Cómo asigno fuente según posición (título, cuerpo, pie de página)?
C) Cómo les asigno el tamaño (font-size) seguún posición?

Muchas gracias,

User avatar
New member

Posts

Joined
Sun Aug 17, 2014 2:43 pm
Location - Venezuela

Post by CoverUp » Sat Oct 24, 2015 12:06 am

Code: Select all

@font-face {
  font-family: 'Libre Baskerville';
  font-style: normal;
  font-weight: 400;
  src: local('Libre Baskerville'), local('LibreBaskerville-Regular'), url(http://fonts.gstatic.com/s/librebaskerville/v4/pR0sBQVcY0JZc_ciXjFsK6Ucnt8gjcHpqyffjHeZWDA.woff2) format('woff2');
}
@font-face {
  font-family: 'Libre Baskerville';
  font-style: italic;
  font-weight: 400;
  src: local('Libre Baskerville Italic'), local('LibreBaskerville-Italic'), url(http://fonts.gstatic.com/s/librebaskerville/v4/QHIOz1iKF3bIEzRdDFaf5eUHi-3yDrzgLLsrfaKVF9k.woff2) format('woff2');
}
otra opción es incrustar el css en modo live

Code: Select all

http://fonts.googleapis.com/css?family=Libre+Baskerville:300,400,600,300italic,400italic,600italic
para asignación, posición y todo lo demas usas la asignacion css normal

saludos

Desarrollador OpenCart: Chilexpress, Correos de Chile, Tur-Bus, Pullman Bus, Starken, WebPay Plus, Servipag y otros a pedido. Todos los trabajos estan garantizados y con factura electrónica.


Active Member

Posts

Joined
Tue Oct 21, 2014 12:22 am
Who is online

Users browsing this forum: No registered users and 4 guests