[RESOLVED] populating an <li> element-VBForums
Results 1 to 2 of 2

Thread: [RESOLVED] populating an <li> element

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Feb 2000
    Location
    Dunmow,Essex,England
    Posts
    898

    Resolved [RESOLVED] populating an <li> element

    Hi All,

    In an ajax call I have data returned in my response object. against an attribute failReason such that response.failReson returns in the form:

    1 : text1, 2: text2, 3: text3.

    if I do the following then I recive everything on a single line as you would expect:

    Code:
    $(".validation-summary-errors").append("<li class='errs'>" + response.failReason + "</li>");
    what I really want is to see text1, text2, text3 as a list. So I thought I'd try the following but JQuery simply doesn't like it:

    Code:
    if (response.failReason) {
                            $(".errs").remove();
                            var fr = "{" + response.failReason + "}";
                            $H(fr).each(function (pair) {
                                $(".validation-summary-errors").append("<li class='errs'>" + pair.value + "</li>");
                            });
                        }
    any ideas anybody?

  2. #2
    Super Moderator Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,335

    Re: [RESOLVED] populating an <li> element

    This is marked resolved but there is no posted solution.

    If you figured this out on your own, please post your resolution as it might help others with the same or similiar problem.

    Thanks.
    Please use [Code]your code goes in here[/Code] tags when posting code.
    When you have received an answer to your question, please mark it as resolved using the Thread Tools menu.
    Before posting your question, did you look here?
    Got a question on Linux? Visit our Linux sister site.
    I dont answer coding questions via PM or EMail. Please post a thread in the appropriate forum section.

    Creating A Wizard In VB.NET
    Paging A Recordset
    What is wrong with using On Error Resume Next
    Good Article: Language Enhancements In Visual Basic 2010
    Upgrading VB6 Code To VB.NET
    Microsoft MVP 2005/2006/2007/2008/2009/2010/2011/2012/Defrocked

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Featured


Click Here to Expand Forum to Full Width

Survey posted by VBForums.