I have requirement like ..

I have to put one link in the Drupal Form, That i achieve with using suffix while creating Drupal form..

Now I want to pop up the list of all drupal users & their email ids with checkboxes by on click that Link..

now if i choose the check box in front of particular user .. the name of the users with semicolons replace that link that i made with suffix..

so how to achieve that...? Any suggestions guys..?

  • hello and welcome. Allow me to remind you that you are expected to search, and research before you ask. and of course share your research with us. If you are asking without prior research, it is a bit unfair - we are not here to do your work for you, for free. We are here to help each other, not to do the whole work for somebody. Sometimes we are not so strict about that, especially if person asking answered far more question than she asked, but that's about it. And if you did your research, we need to know what failed, to avoid suggesting it.
    – Mołot
    Apr 18, 2014 at 8:17
  • i am still student & i am learning Drupal & doing my final year project..so i not have that much idea.. sorry..actually i researched alredy buddy, got pop up & pop up forms module in drupal also but i cant achieve what i want,.. i can pop up the form with the help of jquery but i just want to know that how can replace that link..
    – sanjay
    Apr 18, 2014 at 9:15

1 Answer 1


What you need is pretty much a huge select box :)

i can think to a couple of different approaches, but to mention one, i would proceed like this

  1. Create your form and set the default values obviously.

  2. At the end of your form add a that will wrap around the list of possible choices

  3. Target that with the show/hide script triggered by the click on the link.

  4. Create the list, using either a table or several divs, as long as you give each row an #id, something like user-$uid".

  5. since you are here you can even set a class for the rows that will highlights the row on hover.

  6. Split each row into, assuming tables, cells and populate the table with the user data you need. give each cell the same #id of its row, extend with something else to obtain things like

    "user-$uid-mail" "user-$uid-name"

  7. I would avoid the checkboxes and go with an onClick event on each row, that calls a function passing the row #id as parameter.

  8. The function will, hide the list, use the row #id to read the values of the fields, like


and write the values inside the form elements.

profit. i may have typed some function wrong, but that's the idea

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.