JQuery Lesson Issue



When I click Save & Submit Code I get an error message saying "It looks like you hid BOTH divs - you should only hide the div with ID #green." When the code runs, the div which is green disappears, and the one which is red does not. The code I have is correct, but the system is saying it is incorrect and will not let proceed to the next part of the course.


    <div id="green"></div>


$(document).ready(function() {


Are you showing us all the HTML? It won't work with just that above.


No that is not all of the HTML code. It's all of the HTML that comes already written in that exercise. I just copy and pasted the relevant HTML code that the jquery function is calling.


I only ask because the JS works and passes for me, given the complete HTML.


So I just downloaded Google Chrome and tried doing it in that and it worked fine. I was originally using Safari and it would not pass for some reason. I'm not quite sure why, but I will just continue on with Chrome for the rest of the lesson. Thanks for giving it a go, as you informing me that code worked fine pretty much confirmed that something different was going on other than incorrect coding.


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