Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

JSP combobox problem

Options
  • 01-05-2012 7: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