I have following html code (data coming in the variable as UTF-8)
<p style="margin: 0; font-size: 14px; font-family: Helvetica, Arial, sans-serif;">
Project Name: <span th:text="${projectName}">ProjectName</span>
</p>
Any special character that is in ${projectName} , for example : "Carol's" is getting converted to "Carol?s" in Outlook mail. Anyway to correct this in Thymeleaf ?
Related
<h3 style="text-align:start;"><span style="color: rgb(97,189,109);font-size: 24px;font-family: Source Sans Pro;">(optional) customChunkRenderer</span></h3>
<p><span style="color: rgb(51,51,51);font-size: 18px;font-family: Source Sans Pro;">Use to define additional HTML nodes. Only supports atomic blocks.</span></p>
the above code has to be sanitized in react, like
use jsx and convert this to jsx format
use this -
<h3 style={{textAlign: 'start'}}><span style={{color: 'rgb(97,189,109)', fontSize: 24, fontFamily: 'Source Sans Pro'}}>(optional) customChunkRenderer</span></h3>
<p><span style={{color: 'rgb(51,51,51)', fontSize: 18, fontFamily: 'Source Sans Pro'}}>Use to define additional HTML nodes. Only supports atomic blocks.</span></p>
Is there a work around to make country flag emoji visible on windows 10 through HTML?
<!DOCTYPE html>
<html>
<style>
body {
font-size: 40px;
}
</style>
<body>
<p>9983 will display โฟ</p>
<p>How to display American or Japanese flags?</p>
<p>๐บ๐ธ is just letters on Windows 10 ๐</p>
</body>
</html>
I found this on https://mdbootstrap.com/docs/jquery/content/flag/
I don't see a flag emoji on https://www.w3schools.com/charsets/ref_emoji.asp
I can view them on https://www.emojicopy.com/ but cannot use.
I found a CSS flag on
https://github.com/pixelastic/css-flags/blob/master/app/styles/_flags/usa.scss
I'm still learning to use stackOverflow, and I'm new at coding.
This is my fourth try at this question.
Use Noto Color Emoji font.
First, write a #font-face rule with the unicode-range property. Then add the font to the top of your font stack:
(Source)
#font-face {
font-family: NotoColorEmojiLimited;
unicode-range: U+1F1E6-1F1FF;
src: url(https://raw.githack.com/googlefonts/noto-emoji/main/fonts/NotoColorEmoji.ttf);
}
div {
font-family: 'NotoColorEmojiLimited', -apple-system, BlinkMacSystemFont,
'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji',
'Segoe UI Emoji', 'Segoe UI Symbol';
}
<div>
<p>
๐ฆ๐ซ ๐ฆ๐ฑ ๐ฉ๐ฟ ๐ฆ๐ฉ ๐ฆ๐ด ๐ฆ๐ฌ ๐ฆ๐ท ๐ฆ๐ฒ ๐ฆ๐บ ๐ฆ๐น ๐ฆ๐ฟ ๐ง๐ธ ๐ง๐ญ ๐ง๐ฉ ๐ง๐ง ๐ง๐พ ๐ง๐ช ๐ง๐ฟ ๐ง๐ฏ ๐ง๐น ๐ง๐ด ๐ง๐ฆ ๐ง๐ผ ๐ง๐ท ๐ง๐ณ ๐ง๐ฌ ๐ง๐ซ ๐ง๐ฎ ๐จ๐ป ๐ฐ๐ญ ๐จ๐ฒ ๐จ๐ฆ ๐จ๐ซ ๐น๐ฉ ๐จ๐ฑ ๐จ๐ด ๐ฐ๐ฒ ๐จ๐ฉ ๐จ๐ท ๐จ๐ฎ ๐ญ๐ท ๐จ๐บ ๐จ๐พ ๐จ๐ฟ ๐ฐ๐ต ๐จ๐ฌ ๐ฉ๐ฐ ๐ฉ๐ฏ ๐ฉ๐ฒ ๐ฉ๐ด ๐ช๐จ ๐ช๐ฌ ๐ธ๐ป ๐ฌ๐ถ ๐ช๐ท ๐ช๐ช ๐ธ๐ฟ ๐ช๐น ๐ซ๐ฏ ๐ซ๐ฎ ๐ซ๐ท ๐ฌ๐ฆ ๐ฌ๐ฒ ๐ฌ๐ช ๐ฉ๐ช ๐ฌ๐ญ ๐ฌ๐ท ๐ฌ๐ฉ ๐ฌ๐น ๐ฌ๐ณ ๐ฌ๐ผ ๐ฌ๐พ ๐ญ๐น ๐ญ๐ณ ๐ญ๐บ ๐ฎ๐ธ ๐ฎ๐ณ ๐ฎ๐ฉ ๐ฎ๐ท ๐ฎ๐ถ ๐ฎ๐ช ๐ฎ๐ฑ ๐ฎ๐น ๐ฏ๐ฒ ๐ฏ๐ต ๐ฏ๐ด ๐ฐ๐ฟ ๐ฐ๐ช ๐ฐ๐ฎ ๐ฐ๐ผ ๐ฐ๐ฌ ๐ฑ๐ฆ ๐ฑ๐ป ๐ฑ๐ง ๐ฑ๐ธ ๐ฑ๐ท ๐ฑ๐พ ๐ฑ๐ฎ ๐ฑ๐น ๐ฑ๐บ ๐ฒ๐ฌ ๐ฒ๐ผ ๐ฒ๐พ ๐ฒ๐ป ๐ฒ๐ฑ ๐ฒ๐น ๐ฒ๐ญ ๐ฒ๐ท ๐ฒ๐บ ๐ฒ๐ฝ ๐ซ๐ฒ ๐ฒ๐จ ๐ฒ๐ณ ๐ฒ๐ช ๐ฒ๐ฆ ๐ฒ๐ฟ ๐ฒ๐ฒ ๐ณ๐ฆ ๐ณ๐ท ๐ณ๐ต ๐ณ๐ฑ ๐ณ๐ฟ ๐ณ๐ฎ ๐ณ๐ช ๐ณ๐ฌ ๐ฒ๐ฐ ๐ณ๐ด ๐ด๐ฒ ๐ต๐ฐ ๐ต๐ผ ๐ต๐ฆ ๐ต๐ฌ ๐ต๐พ ๐ต๐ช ๐ต๐ญ ๐ต๐ฑ ๐ต๐น ๐ถ๐ฆ ๐ฐ๐ท ๐ฒ๐ฉ ๐ท๐ด ๐ท๐บ ๐ท๐ผ ๐ฐ๐ณ ๐ฑ๐จ ๐ป๐จ ๐ผ๐ธ ๐ธ๐ฒ ๐ธ๐น ๐ธ๐ฆ ๐ธ๐ณ ๐ท๐ธ ๐ธ๐จ ๐ธ๐ฑ ๐ธ๐ฌ ๐ธ๐ฐ ๐ธ๐ฎ ๐ธ๐ง ๐ธ๐ด ๐ฟ๐ฆ ๐ธ๐ธ ๐ช๐ธ ๐ฑ๐ฐ ๐ธ๐ฉ ๐ธ๐ท ๐ธ๐ช ๐จ๐ญ ๐ธ๐พ ๐น๐ฏ ๐น๐ญ ๐น๐ฑ ๐น๐ฌ ๐น๐ด ๐น๐น ๐น๐ณ ๐น๐ท ๐น๐ฒ ๐น๐ป ๐บ๐ฌ ๐บ๐ฆ ๐ฆ๐ช ๐ฌ๐ง ๐น๐ฟ ๐บ๐ธ ๐บ๐พ ๐บ๐ฟ ๐ป๐บ ๐ป๐ช ๐ป๐ณ ๐พ๐ช ๐ฟ๐ฒ ๐ฟ๐ผ
</p>
<p>
Noto Color Emoji abcdefghijklmnopqrstuvwxyz0123456789
</p>
</div>
Flags don't seem to work on Windows due to political reasons, see https://answers.microsoft.com/en-us/windows/forum/all/flag-emoji/85b163bc-786a-4918-9042-763ccf4b6c05?page=1
This thread seems to have found a workaround
Flag Emojis not rendering
Windows includes the Segoe UI Emoji font, but it does not support flags. To see flag emoji on Windows 10, you'll have to provide a custom emoji font that does support flags.
There's an ISO standard with two-letter codes for countries, like "JP" for Japan. In Unicode, the emoji flags are encoded as a pair of special characters that correspond to "A" to "Z", but that are different characters from A-Z. You can see the different sequences at https://unicode.org/emoji/charts/full-emoji-list.html#country-flag. For example, for the Japanese flag the sequence U+1F1EF U+1F1F5 is used. To encode those in a Web page, you can use character entities ๐ฏ๐ต: "๐ฏ๐ต". If the browser / host OS support display of emoji flags, that's what you'll see. If not, you'll probably see something that looks like "JP".
The problem is that the Windows' default emoji font, Segoe UI Emoji, has the 26 country flag letter codepoints the country flags are composed of, but has only letters representing them, so the flags will always be rendered as the Segoe UI Emoji letters unless an application explicitly declares that another Emoji Font is to be preferred.
Luckily, you can just replace the Windows Emoji font by taking another Emoji Font and changing its internal name to Segoe UI Emoji.
I did that for Google's Noto Emoji font, which you can download at https://github.com/perguto/Country-Flag-Emojis-for-Windows.
I have just started learning HTML and I am having problems with IDs/classes within IDs/classes.
So, to my knowledge, an ID is specified by a #. That would mean that if I wanted to style an ID within and ID, wouldn't that be:
#ID1 #ID2 {
...
}
Which would mean that the styling will only apply for ID2 that is inside ID1? Please correct me if I'm wrong. When I used the same principle within my (very simple beginner) code, it didn't work. Here is my code:
<!DOCTYPE html>
<html>
<head>
<title>1 May 2016</title>
<style>
#name {
color: blue;
font-family: Tahoma;
}
#parafont #1 {
font-family: Arial;
}
#parafont #2 {
font-family: Times;
}
#parafont #3 {
font-family: Courier;
}
parafont #4 {
font-family: Lucida Grande;
}
#parafont #5 {
font-family: Helvetica;
}
#test1 #6 {
color: blue;
}
</style>
</head>
<body>
<h3 id="name">Bob Bobbington</h3>
<p>1 2 3 4 5 6 7 8 9 10</p>
<p>When was this website created? Check the <b>title</b>.</p>
<h3>All animals are quite interesting...</h3>
<p id="parafont">
<span id="1">This is a test paragraph.</span>
<span id="2">Each sentence should have a different font.</span>
<span id="3">This paragraph is going to use some styling.</span>
<span id="4">Styling will change the font of each sentence.</span>
<span id="5">Let's see whether it works!</span>
</p>
<div id="test1">
<p id="6">Test</p>
</div>
</body>
</html>
All help is very much appreciated!
Change the id numbers 1 to something that starts with letters.
ID and NAME tokens must begin with a letter ([A-Za-z]) and may be
followed by any number of letters, digits ([0-9]), hyphens ("-"),
underscores ("_"), colons (":"), and periods (".").
IDs can not start with numbers first of all. Also since IDs are meant to be specific, using nesting to select an element is redundant. #id #id2 would be the same thing as just #id2 as long as the more specific #id #id2 was used
I'm pretty new in objective C
I try to pass a NSString containing some html and css to my webview :
[_webView loadHTMLString:htmlString baseURL:nil];
The string :
#"<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01//EN\">\n<html>\n <head>\n <style type=\"text/css\">\n
body {\n font-family: \"Gill sans\";\n font-size: 12pt;\n color: #808080;\n margin: 0px;\n }\n
a:link, a.visited, a:active {\n font-style: normal;\n color: #ffffff;\n text-decoration: underline;\n }\n
.accroche {\n font-size: 19pt;\n color: #ffffff;\n text-align : center;\n }\n
#title {\n \n text-transform : capitalize;\n }\n
</style>\n
</head>\n
<body>\n
<div id=\"title\">Informations Utiles</div>\n
<p><span class=\"accroche\"><p>blablahblablablah<br /> blabla<br />blabla <br /> </p></span></p>\n
</body>\n</html>\n"
Sorry about the formatting but i don't want to change it too much as it may hide things.
Problem is, on the screen in the simulator, css is just ignored, capitalize wont work, as well as text-align or font-size, anything...
Any idea?
I have tried this on a real device and it renders correctly. This is a simulator issue :(
I was using Xcode 4.3.2 and the simulator running iOS5.1.
I will raise this as a bug with Apple, but hopefully this answer will help somebody else in the future!
Hope it helps.
I use sendmailR (ver. 1.0-0) to create automated corporate mails. Inside the mail message I insert html code to produce tables. Finally, before sending, I convert the message to utf8 - since it contains multilingual characters, using
msg <- iconv(msg, to = "utf8")
After migrating to ver. 1.1-2 (in order to send mails with attachments), the contents of the mail cannot be read anymore. The text is unreadable and the html code is ignored. This is an example of the contents after upgrading:
รยณรยนรยฑ รโรยฟ รยผรยฎรยฝรยฑ รโรยตรยบรยญรยผรยฒร รยนรยฟ (รยฑรยฝรยฌ รฦร รยผรยฒรยฑรฦรยท รยบรยฑรยน รยฑรยธร รยฟรยนรฦรโรยนรยบรยฌ), รยญรโกรยฟรโฆรยฝ รโฐรโ รยตรยพรยฎรโ.<br><br> <b>รโรยฝรยฌ รลกรยฑรโรยทรยณรยฟร รยฏรยฑ รยบรยฑรยน รยฃร รยผรยฒรยฑรฦรยท</b><br>
<table style='border-collapse: collapse; border-color: rgb(136, 136, 136); border-width: 1px;' border='1' bordercolor='#888888' cellspacing='0'>
<tbody><tr>
<td style='text-align: center; width: 40px; height: 20px;'> รโ.A.</td>
Do you suggest to continue using the initial version?
Thank you