Learn how Script Tags.. what am i doing wrong?

Its not valid i guess, whyyyy

Your code so far

        $(document).ready(function() {

<!-- Only change code above this line. -->

<div class="container-fluid">
  <h3 class="text-primary text-center">jQuery Playground</h3>
  <div class="row">
    <div class="col-xs-6">
      <div class="well" id="left-well">
        <button class="btn btn-default target" id="target1">#target1</button>
        <button class="btn btn-default target" id="target2">#target2</button>
        <button class="btn btn-default target" id="target3">#target3</button>
    <div class="col-xs-6">
      <div class="well" id="right-well">
        <button class="btn btn-default target" id="target4">#target4</button>
        <button class="btn btn-default target" id="target5">#target5</button>
        <button class="btn btn-default target" id="target6">#target6</button>

Your browser information:

Your Browser User Agent is: Mozilla/5.0 (iPad; CPU OS 11_0_1 like Mac OS X) AppleWebKit/604.1.38 (KHTML, like Gecko) Version/11.0 Mobile/15A402 Safari/604.1.

Link to the challenge:

That extra > after the semi-colon is causing an error.

Your opening script tag is incomplete, it should look like this:

$(document).ready(function() {

Also, this script should be the last element placed within the <body>. The current placement, which is before the majority of the HTML code, isn’t usually the ideal placement for script elements, and you typically want to run scripts after your page has loaded, which means placing your scripts as the very last element before your </body> closing tag.

Well you might not be allowed to change the placement if this is an FCC exercise, but that’s something you should keep in mind once you move on to creating your own HTML files on your own computer.

1 Like