how to get both "value" and "name" ?

ffadly's Avatar


08 Apr, 2010 04:48 AM

can i get the value of data "value" and "name" ?

pre data :
`var preData = {items: [

    <c:forEach var="pre" items="${preData}">
        {value: "${}", name: "${pre.displayname}"},

and the code :

`$("#assignedDisplay").autoSuggest("<%=ajaxResourceURLUserList%>", {

    selectedItemProp: "name",
    selectedValuesProp: "value",
    startText:"Enter a name here!",
    searchObjProps: "name",
    selectionLimit: 1,
    asHtmlID: "assignedUser",
    emptyText: "No User Found!",
    preFill: preData.items,
    resultClick: function(){
         var to = document.getElementById("as-values-assignedUser").value;
        document.getElementById("assignedDisplayName").value = to;
  1. 1 Posted by hero on 13 May, 2010 01:28 PM

    hero's Avatar

    i also really wonder the solution of this problem, it took 2 hours bur still no success!

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac