Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

JSP combobox problem

  • 01-05-2012 07:56PM
    #1
    Closed Accounts Posts: 82 ✭✭


    I am working on my FYP and i need to create new jobs that will be added to the database.At the moment i am trying to populate the combobox with skills from the database.My problem is with the following JSP code is that the combobox is diplayed on the page but no skills are in the dropdown??% Also there is a textfield appearing above the combobox that i have not asked to display.Thanks

    JSP:

    <s:form action="createJobs">
    <s:textfield name="jobName" label="Job Name" />
    <s:textfield name="startDate" label="Start Date"/>
    <s:textfield name="endDate" label="End Date" />
    <s:textfield name="salary" label="Salary" />
    <s:textfield name="description" label="Description" />
    <s:combobox label="Skill" name="skillName" list="skills"/>
    <s:submit />
    </s:form>




    session.put("skillName", getSkillName());
    session.put("skills", this.skills);
    this.skillsQuery();//populate skillsSet
    this.skills = new ArrayList<Skill>();

    System.out.println("before");
    Collections.sort(skills);
    System.out.println("after");
    session.put("skills", this.skills);
    System.out.println(skills.size());


Advertisement