mirror of
https://github.com/neocities/neocities.git
synced 2025-04-24 17:22:35 +02:00
37 lines
1.1 KiB
Text
37 lines
1.1 KiB
Text
<div class="comic" style="height: 600px; background-image: url(/img/tutorial/ch1pg8.png); background-size: 489px;">
|
|
<div class="dialogue">
|
|
Now add a link to one of your list items. If nested properly, it should look something like this:
|
|
<br><strong><li><a href="http://yarn.com">Yarn</a></li></strong>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="welcome">
|
|
<h4>Tags so far</h4>
|
|
<p>Headings: <h1>Title of the page!</h1>
|
|
<h2>Less important title</h2></p>
|
|
|
|
<p>Paragraphs: <p>Hello!</p></p>
|
|
|
|
<p>Links: <a href="http://wikipedia.org">Click here!</a></p>
|
|
|
|
<p>Images: <img src="hello.png"></p>
|
|
|
|
<p>Lists</p>
|
|
</div>
|
|
|
|
<script>
|
|
function checkHomework() {
|
|
var html = editor.getValue()
|
|
|
|
/* TODO: Make .+ ignore any spaces or newlines or whatever. </a> lol </p> is fine too. */
|
|
var match = '<html.+>.+<body>.+<ul>.+<li><a.+href=".+">.+</a></li>.+</ul>.+</body>.+</html>'
|
|
var re = new XRegExp(match, 'gis')
|
|
|
|
if(html.match(re) === null) {
|
|
notok("That's not right! Try again.")
|
|
} else {
|
|
sessionStorage.setItem('tutorialHtml', html)
|
|
ok('Great, you did it!', '/tutorial/html/9')
|
|
}
|
|
}
|
|
</script>
|