- Posts: 18
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Changing font with CSS
- Baarceri_122875
- Topic Author
- Offline
- Banned
Less
More
6 years 1 month ago #165403
by Baarceri_122875
Changing font with CSS was created by Baarceri_122875
Hi there,
I am new to CSS and have been trying to change the font by editing the 'flat_and_modern.css' file in the template editor. However, when I save changes, I get a 'This page isn't working' browser error. When I reload, the changes do appear to have been saved, but have no effect on the way the font looks when loading the survey.
I have edited the top of the CSS file to the following, as an example:
Any idea what I am doing wrong? I am using the Pro version of LimeSurvey.
Regards,
Will
I am new to CSS and have been trying to change the font by editing the 'flat_and_modern.css' file in the template editor. However, when I save changes, I get a 'This page isn't working' browser error. When I reload, the changes do appear to have been saved, but have no effect on the way the font looks when loading the survey.
I have edited the top of the CSS file to the following, as an example:
Code:
/* lato-regular - latin */ @font-face { font-family: Arial; font-style: normal; font-weight: 400; } /* lato-italic - latin */ @font-face { font-family: Arial; font-style: italic; font-weight: 400; } /* lato-700 - latin */ @font-face { font-family: Arial; font-style: normal; font-weight: 700; }
Any idea what I am doing wrong? I am using the Pro version of LimeSurvey.
Regards,
Will
The topic has been locked.
- jelo
- Offline
- Platinum Member
Less
More
- Posts: 5033
- Thank you received: 1257
6 years 1 month ago #165404
by jelo
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Replied by jelo on topic Changing font with CSS
What version of LimeSurvey is used? It's at the bottom of the page.
Since you're a paying customer you might open directly a ticket with the LS GmbH support. Look at your profile here on Limesurvey.org. Or via the support link in the top right corner.
You might post a link to a demosurvey with your modified template. There are some CSS gurus in the forum, which might point in the right direction.
In LS 3.0 you could easily choose the fonts without touching the CSS manually.
Since you're a paying customer you might open directly a ticket with the LS GmbH support. Look at your profile here on Limesurvey.org. Or via the support link in the top right corner.
You might post a link to a demosurvey with your modified template. There are some CSS gurus in the forum, which might point in the right direction.
In LS 3.0 you could easily choose the fonts without touching the CSS manually.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The topic has been locked.
- Baarceri_122875
- Topic Author
- Offline
- Banned
Less
More
- Posts: 18
- Thank you received: 0
6 years 1 month ago #165408
by Baarceri_122875
Replied by Baarceri_122875 on topic Changing font with CSS
Hi Jelo,
The version number on screen is 2.73.1. It is the LimeSurvey hosted version, currently a free account while I design the survey. How could I change it to Version 3?
Will
The version number on screen is 2.73.1. It is the LimeSurvey hosted version, currently a free account while I design the survey. How could I change it to Version 3?
Will
The topic has been locked.
- jelo
- Offline
- Platinum Member
Less
More
- Posts: 5033
- Thank you received: 1257
6 years 1 month ago #165410
by jelo
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Replied by jelo on topic Changing font with CSS
I never use the hosted version on LimeSurvey. If you are evaluating LimeSurvey I would ask the support to change your account or recreate your account to get LS 3 instead of LS 2.7. There might is a button to convert. Don't know, sorry.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The following user(s) said Thank You: Baarceri_122875
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10098
- Thank you received: 3589
6 years 1 month ago #165439
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Changing font with CSS
It looks to me like you are declaring a font, not actually applying it. Also, in 2.7x, I recommend making all CSS changes in template.css. This file is loaded last.
So, if you want to force the use of Arial, something like this at the end of template.css:
So, if you want to force the use of Arial, something like this at the end of template.css:
Code:
body { font-family: Arial, sans-serif; }
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: Baarceri_122875
The topic has been locked.
- Baarceri_122875
- Topic Author
- Offline
- Banned
Less
More
- Posts: 18
- Thank you received: 0
6 years 1 month ago #165446
by Baarceri_122875
Replied by Baarceri_122875 on topic Changing font with CSS
Thanks Tony,
That will do it! Looks like I might have to learn how to use CSS better!
Will
That will do it! Looks like I might have to learn how to use CSS better!
Will
The topic has been locked.
- davebostockgmail
- Offline
- Elite Member
Less
More
- Posts: 166
- Thank you received: 26
6 years 1 month ago #165454
by davebostockgmail
Replied by davebostockgmail on topic Changing font with CSS
Not sure if this helps but CSS loads in order so by putting your changes at the top of the file any instructions below it will take over.
as an example ...
body {
font-family : arial;
font-family : tahoma; }
would result in the font being tahoma and not arial....
Have you tried putting it at the bottom of the file ... or finding the entry and just replacing it so that there is no redundancy?
as an example ...
body {
font-family : arial;
font-family : tahoma; }
would result in the font being tahoma and not arial....
Have you tried putting it at the bottom of the file ... or finding the entry and just replacing it so that there is no redundancy?
The topic has been locked.
- Baarceri_122875
- Topic Author
- Offline
- Banned
Less
More
- Posts: 18
- Thank you received: 0
6 years 1 month ago #165457
by Baarceri_122875
Replied by Baarceri_122875 on topic Changing font with CSS
Yes, I used the solution Tony provided. Putting the body font at the end of the template CSS, which worked fine.
Will
Will
The topic has been locked.