Before and After... Error


#1


https://www.codecademy.com/courses/web-beginner-en-v6phg/0/3?curriculum_id=50a3fad8c7a770b5fd0007a1


Error Message: Oops, try again. It looks like you didn't insert your p after the div with ID #one.


// script.js
$(document).ready(function () {
  $('#one').after('This is not a div.')  
});

//index.html
<!DOCTYPE html>
<html>
	<head>
		<title>Result</title>
        <script type='text/javascript' src='script.js'></script>
	</head>
	<body>
        <div class="container">
            <h2>Greetings</h2>
            <div id="one">Div #1</div>
            <div id="two">Div #2</div>
        </div>   
	</body>
</html>


#2

Oops, try again. It looks like you didn't insert your p after the div with ID #one.

<p>I'm a paragraph element.</p>

#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.