This won't work... Create a new post


var main = function() {
$('.btn').click(function() {
var post = $('.status-box').val();

  • ').text(post).prependTo('.posts');
    This wont work.

  • #2

    Having trouble with this also. Did you ever get this corrected?


    Hi James,

    Next time, please give the error message you're getting - it generally makes debugging your code easier for us.

    In this case, it wasn't too hard to figure out though :)
    You need to run main() once the page is loaded. You can do that by adding this to the bottom of app.js:


    I hope this helps, please let me know if you're still having trouble with the exercise :)


    A post was split to a new topic: Posts don't contain any text when added