Copy link to clipboard
Copied
When html-page uses a font-family tag, the result is different in a web browser from what Dreamweaver shows in preview. Especially, number 0 shows in the browser with diagonal line inside the number. This may be misleading and affect readability. Thanks.
Well that's your problem. Use universal character encoding of UTF-8, not iso-8859-1.
Copy link to clipboard
Copied
Are you using Live View when you are previewing in Dreamweaver? Could you show a screenshot of what you are seeing?
Copy link to clipboard
Copied
Hello,
I'm referring to the preview pane above the html-code pane in the split view of the Dreamviewer main pane. Thanks.
Copy link to clipboard
Copied
You can't predict which fonts are available on all devices so you make a font-family from a web-safe list of fonts with similar characteristics.
As an example,
body {
font-family: Calibri, Candara, Segoe, Segoe UI, Optima, Arial, sans-serif;
font-size: calc(16px + 1vw);
line-height: calc(1.1em + 0.5vw);
}
When 1st font isn't available, the 2nd font is displayed, or the 3rd or 4th, etc... until one matches the device fonts.
As seen in Dreamweaver Live View.
As seen in latest Firefox desktop browser:
Since this is being viewed from the same device, the fonts are identical.
On another device, the fonts may be different.
If you're experiencing other problems, be sure to validate code and fix reported errors.
HTML https://validator.w3.org/
CSS https://jigsaw.w3.org/css-validator/
Hope that helps.
Copy link to clipboard
Copied
Thanks for the overview. However, using the Lucida Grande...Verdana font family on the same device, the number 0 had apparently changed to the font with a diagonal line inside the character in Chrome/Mac/Monterey.
Copy link to clipboard
Copied
Thanks for the overview. However, using the Lucida Grande...Verdana font family on the same device, the number 0 had apparently changed to the font with a diagonal line inside the character in Chrome/Mac/Monterey.
By @Avatar55977840
The only time I have seen strange font behavior on a Mac prior is when there is a corrupt font on the system. Has this problem only started to occur recently, and if so, can you try disabling some of the newly installed fonts to see if this remedies the issue.
Copy link to clipboard
Copied
Which language & character set are defined in your HTML document?
HTML5 Example:
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
Copy link to clipboard
Copied
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
Copy link to clipboard
Copied
Well that's your problem. Use universal character encoding of UTF-8, not iso-8859-1.
Copy link to clipboard
Copied
Thanks, I appreciate it.