+ 1

How to write example code in Html?

For example I used <code> attribute to write my html code and symbol < and > I wrote with &lt; and &gt; and I used class to give color.So it works well ,but it's very difficult to write everytime &lt; &gt; and write classes.Who can tell me the easiest way to do it .Sorry for my English.

18th Jun 2018, 9:18 AM
Fury
3 Antworten
+ 4
Hello, Fury ! Please try a very good tag <xmp><p>My code</p></xmp> Good luck!
18th Jun 2018, 9:23 AM
Alexander Sokolov
Alexander Sokolov - avatar
+ 1
Oh thank you but could I give color to text for example to <html> or <img> or<p> by using xml?
18th Jun 2018, 9:26 AM
Fury
0
xmp*
18th Jun 2018, 9:26 AM
Fury