Reputation: 7308
I am trying to add a wiki page on GitHub that contains sample HTML but can't figure out how to display the actual HTML, not try to render it.
I tried & lt; & gt; and < < but then it renders it like
& lt;table& gt;
Upvotes: 17
Views: 31522
Reputation: 677
Tip: You can also display 'inline' HTML by adding a single backtick:
`<html>`
Upvotes: 11
Reputation: 5929
If you want display HTML as code sample. You can use formatting for code
Examples:
```html
<!DOCTYPE html>
<html>
<head>
<title>This is a title</title>
</head>
<body>
<p>Hello world!</p>
</body>
</html>
```
```xml
<?xml version="1.0" encoding="ISO-8859-1" ?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
</xs:schema>
```
Upvotes: 21