Exemplo n.º 1
0
 /**
  * This method gets called EVERY time the object is
  * created.  It is used to build all of the 
  * FormElement objects used in this Form.
  *
  */
 function form_init_elements()
 {
     $this->add_hidden_element("swimmerid");
     //  This is used to remember the action
     //  which originated from the GUIDataList.
     $this->add_hidden_element("_action");
     //  First Name field
     $firstname = new FEText("First Name", true, "200px");
     $this->add_element($firstname);
     //  Middle Name field
     $middlename = new FEText("Middle Name", false, "200px");
     $this->add_element($middlename);
     //  Last Name field
     $lastname = new FEText("Last Name", true, "200px");
     $this->add_element($lastname);
     //  Birth Date field
     $birthdate = new FEDate("Birth Date", true, null, null, "Fdy", date("Y") - 25, date("Y") + 2);
     $this->add_element($birthdate);
     //  Gender field
     $gender = new FEListBox("Gender", true, "100px");
     $gender->set_list_data($this->GenderSelections());
     $this->add_element($gender);
     //  USS field
     $uss = new FEText("USS", true, "200px");
     $this->add_element($uss);
     //  Calculated USS field
     $ussnew = new FEText("USS New", false, "200px");
     $ussnew->set_disabled(true);
     //$ussnew->set_readonly(true) ;
     $this->add_element($ussnew);
     //  Swim Team field
     $swimteam = new FEListBox("Swim Team", true, "300px");
     $swimteam->set_list_data($this->SwimTeamSelections());
     $this->add_element($swimteam);
 }