Skip to content

Field_model

ghezalahmad edited this page Jun 12, 2012 · 5 revisions

Documentation of Field-model

For defining users fields, we provide a class which contains functions that return all fields of the specified user,like to add a user 's field or to delete user's field. This class is used to show the users interests or field of studies. Like Database, Software Engineering..... etc.

Here is the list of functions that this class contains:

this fuction will create new record in Field table

@param $fieldName is new field name

→ function add_field($fieldName)

To have the possibility to update a users field, it has two parameters $filedID & $fieldName that according given $fieldID we can change the $fieldName. For example, my field is Database, now I have the possibility to change it to “Database System Management “.

→ function update_field($fieldID,$fieldName)

This method is used to returns an array of fields record objects. Like $fieldID,$fieldName and we used some properties like limit (limits the number of returned records), offset (how many records to bypass before returning a record “limit required”), sortBy (determines how the sort take places) and sortDirection (asc,desc).

→ function get_field_data()

This method is used to delete a field's from table. → function delete_field($fieldID)

Back / Back To Main

Clone this wiki locally