Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

CSS

Gerald Torres
Gerald Torres
13,442 Points

Modal window not appearing

In the Frameworks Basics Course I am stuck on Building Modal Windows and Forms. I have done everything perfectly until 04:48. He demonstrates how his modal window appears when he clicks on the button but mine doesnt do the same. Here is my code:

<div class="modal fade" id="textModal"> <div class="modal-dialog"> <div class="modal-content">

      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
        <h4 class="modal-title">We'll Text You the Link!</h4>
      </div>

      <div class="modal-body">
      </div>

    </div>
  </div>

</div>

1 Answer

Samuel Johnson
Samuel Johnson
9,152 Points

Im not too sure what the rest of your code looks like but normally if its not responding im guessing its something to do with javascript not loading in the page. First check whether your getting an error in the console on the browser, you can see this in chrome by pressing 'alt-cmd-j' to bring the console up using chrome the press the button and see if some sort of error is registered?

Also make sure the correct files are being loaded when using a frontend framework? Check the js file is being loaded in the page? its easy to have a spelling mistake in the CDN link if your using one? again you check this in the resources panel (not to sure on the shortcut for this but can easily be found once you have the developer tools up in chrome)

Hope this helps but its the best answer i can give you with what you've provided. :)