It is necessary to generate a simple page in which the title will change, a bit of text and add, decrease elements of the list. How to do in html-I know, but in c # I try to write such info to a file, defining quotes with slashes - the document is written to the file correctly, and in a notebook all tags closing opening quotes and quotes are in place, but the browser does not see markup in this text. Maybe the fact is that the quotes when framing them with a slash are not the same as they should be?
UPD: the problem was probably caused by the fact that the html html code in # visual studio receives extra spaces between special characters (<>) when inserting, and I think that this requires discussion and attention and not a trivial typo.
string content2 = System.String.Format( "<html>" + "<head>" + "<title> Документы {0} {1}</title>" + "< link href =\"../../favicon.ico\" rel=\"icon\" type=\"image/x icon\" />"+ "< link href =\"../../favicon.ico\" rel=\"shortcut icon\" type=\"image/x-icon\" />"+ "< link rel =\"stylesheet\" href=\"../../css.css\" type=\"text/css\" />"+ "</head>" + "<body>" + "{0} {1}" + "</body>" + "</html>", date, textBox_title.Text); #endregion File.WriteAllText("index.html", content2);
браузер не видит в этом тексте разметку? - Andrei NOP<link, then it opens normally - Andrew NOP