Functions | |
| mypage_init () | |
| Implementation of hook_init(). | |
| mypage_menu ($may_cache) | |
| Implementation of hook_menu(). | |
| mypage_module_invoke ($type, &$page, $uid) | |
| Allows other modules to hook into the mypage process. | |
| mypage_admin_user ($uid) | |
| Provides the administrative settings to the mypage user. | |
| mypage_admin_user_validate ($form_id, $form_values) | |
| Companion function handles submission of user settings page. Called by Drupal core. | |
| mypage_admin_user_submit ($form_id, $form_values) | |
| Companion function handles submission of user settings page. Called by Drupal core. | |
| mypage_admin () | |
| Provides the administration settings for the MyPage module and enabled components. | |
| mypage_get_page ($id_name=NULL) | |
| returns a custom page | |
| mypage_mypage ($type, &$data, $uid) | |
| Implements our own hook. | |
| mypage_page_build ($data) | |
| Builds the page based on the data collected from the mypage hook. | |
| mypage_variable_get ($component, $variable, $default=NULL, $uid=0) | |
| Returns a variable for a component. | |
| mypage_variable_set ($component, $variable, $value, $uid=0) | |
| Sets a variable for a mypage componen. | |
| mypage_component_administration ($uid) | |
| Returns the administration component for the page. | |
| _mypage_get_id ($id_name=NULL) | |
| Returns user id. | |
| _mypage_sort_row ($a, $b) | |
| Called by uasort() to sort the page elements by row. | |
| _mypage_sort_col ($a, $b) | |
| Called by uasort() to sort the columns. | |
| int _mypage_get_id | ( | $ | id_name = NULL |
) |
Returns user id.
| $id_name | string containing user name or uid |
| int _mypage_sort_col | ( | $ | a, | |
| $ | b | |||
| ) |
Called by uasort() to sort the columns.
| $a | Array element for comparison. | |
| $b | Array element for comparison. |
| int _mypage_sort_row | ( | $ | a, | |
| $ | b | |||
| ) |
Called by uasort() to sort the page elements by row.
| $a | Array element for comparison. | |
| $b | Array element for comparison. |
| string mypage_admin | ( | ) |
Provides the administration settings for the MyPage module and enabled components.
Issues a type 'settings' from any implemented mypage hook, passing the form to be returned to the user.
| string mypage_admin_user | ( | $ | uid | ) |
Provides the administrative settings to the mypage user.
| $uid | The user id of the user we're getting the settings for. |
| bool mypage_admin_user_submit | ( | $ | form_id, | |
| $ | form_values | |||
| ) |
Companion function handles submission of user settings page. Called by Drupal core.
| $form_id | The form id. | |
| $form_values | The values of the form after submission. |
Issue a mypage hook request for the type 'user settings submit' to allow any modules the opportunity to work on the validated, submitted data from the user settings.
| null mypage_admin_user_validate | ( | $ | form_id, | |
| $ | form_values | |||
| ) |
Companion function handles submission of user settings page. Called by Drupal core.
| $form_id | The form id. | |
| $form_values | The values of the form after submission. |
For validation, we want to pass the form values as an element of the data array. Another element will be return which will be blank. This will contain any errors (form element name and error).
| string mypage_component_administration | ( | $ | uid | ) |
Returns the administration component for the page.
| $uid | The user id of the page requsted. |
| string mypage_get_page | ( | $ | id_name = NULL |
) |
returns a custom page
| $id_name | uid or user name |
Issues a mypage hook type 'page load' so any other components or modules can manipulate the page before it is rendered.
| null mypage_init | ( | ) |
Implementation of hook_init().
| array mypage_menu | ( | $ | may_cache | ) |
Implementation of hook_menu().
| @may_cache | If Drupal is going to cache the returned links or not. |
| null mypage_module_invoke | ( | $ | type, | |
| &$ | page, | |||
| $ | uid | |||
| ) |
Allows other modules to hook into the mypage process.
| $type | Type of action being taken by the module for the call. | |
| &$page | The page being created. Passed by reference. | |
| $uid | The user id being worked on. |
| null mypage_mypage | ( | $ | type, | |
| &$ | data, | |||
| $ | uid | |||
| ) |
Implements our own hook.
| $type | The type of operation being performed. | |
| $data | The page being constructed. Passed by reference. | |
| $uid | The user id of the user we're operating on now. |
| string mypage_page_build | ( | $ | data | ) |
Builds the page based on the data collected from the mypage hook.
| $data | Data returned by the mypage hook. Should be an associative array. |
| string mypage_variable_get | ( | $ | component, | |
| $ | variable, | |||
| $ | default = NULL, |
|||
| $ | uid = 0 | |||
| ) |
Returns a variable for a component.
| $component | The component requesting the variable. | |
| $variable | The name of the variable. | |
| $uid | The uid we are querying for. | |
| $default | The default value returned if the variable isn't found. |
| bool mypage_variable_set | ( | $ | component, | |
| $ | variable, | |||
| $ | value, | |||
| $ | uid = 0 | |||
| ) |
Sets a variable for a mypage componen.
| $component | The component setting the variable. | |
| $variable | The name of the variable. | |
| $value | The value we're setting the variable to. | |
| $uid | The uid we are setting for. |
1.5.3