You are viewing limited content. For full access, please sign in.

Question

Question

Forms Text Customisation

asked on September 11, 2019 Show version history

Is there a quick way to change all text on a form to use a custom font ie not the ones listed in themes?

 

I would like all input fields and headers Paragraph tags, etc to all be the same font.

 

0 0

Replies

replied on September 11, 2019

You can do this with JavaScript:

$('document').onload(function() {
  //target all p and h4 tags (for example)
  $('p, h4').css('font-family', 'arial')
})

You would need to be specific with your target selectors.

See this article for more information on using multiple jQuery selectors.
https://api.jquery.com/multiple-selector/

0 0
replied on September 11, 2019

I have gone down the CSS route, so far i have:

/*Custom Font*/
@font-face{
font-family: lato;
  src: url(https://fonts.googleapis.com/css?family=lato);
}

*{font-family: 'lato';}
body{font-family: 'lato';}
input{font-family: 'lato';}
label.cf-helptext{font-family: 'lato';}
.form-option-label{font-family: 'lato';}
.section-header{font-family: 'lato';}
.cf-label{font-family: 'lato';}
.cf-custom{font-family: 'lato';}
.cf-collection-block{font-family: 'lato';}
.cf-form-q{font-family: 'lato';}
.cf-helptext{font-family: 'lato';}
.ab-help{font-family: 'lato';}
.radioFields{font-family: 'lato';}

 

0 0
replied on September 11, 2019

Replace lines 02-05 with:

@font-face{
  font-family: 'lato';
  src: url(https://fonts.gstatic.com/s/lato/v16/S6uyw4BMUTPHjx4wXg.woff2) format('woff2');
}

 

1 0
replied on September 11, 2019

Good Shout yes

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.