Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript JQuery Form Success Function

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #36261
    jayjo44
    Member

    I have been struggling with what I feel is a simple JQuery selector issue, but I’ve been messing around with it for some time now and can’t seem to get the desired outcome.

    I have an unordered list containing multiple li’s, which are each siblings to hidden div containing a form element; so I essentially have multiple forms on a page. Without using IDs or additional classes, I would like to be able to “hide” or “slideUp” the current “hidden” div element upon submitting its corresponding form.

    // if(data == “Thank you for your submission. A representative will contact you soon.”){ ‘close form containing div’ }

    Any help would be most appreciated. A live version of the site and issue can be seen here: http://clients.jayjodesign.com/executive-council/staging/events.php

    Thanks,
    JayJo

    #95205
    jamygolden
    Member

    I’d say the first thing you should do is validate your markup.

    A <ul> should only contain <li> elements as it’s children.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.