. */ class CandAEGEEConferences extends Cand { /* Constructor * Make sure you set the name, and, when needed, if the field is * compulsory */ public function __construct($candidate_id) { $this->candidate_id = $candidate_id; $this->name = "AEGEEConferences"; $this->compulsory = true; } /* get_print_name() * Return the name of the field (caption) to be shown in the application * form */ public function get_print_name() { return "Attended AEGEE conferences"; } /* get_print_name_short() * Return the name of the field (caption) to be shown in a table */ public function get_print_name_short() { return "AEGEE conferences"; } /* get_print_value($readonly) * Return the value to be printed in the form (with text boxes etc) * @param: readonly: if the field can be changed (false) or not (true) */ public function get_print_value($readonly=false) { global $setup; $r = ""; $r .= "
How many AEGEE conferences have you visited, and which one(s)?"; $r .= "
You can also fill in visited AEGEE-Academy trainings here."; return $r; } /* set($value) * Check the supplied value and assign it if ok (return true), otherwise * set an error and return false * @param: value: the value to be assigned and checked * @return: true on ok, false on error */ public function set($value) { if( strlen($value)>0 ) { $this->value = $value; return true; }else { $this->error = true; $this->error_txt = "Please fill in how many AEGEE conferences you have visited.\n"; return false; } } } ?>