Introduced in: 11 Jun 2005 by Fredrik Thulin <ft@it.su.se>
Authors: Fredrik Thulin (ft@it.su.se).
error/1 | Create a red error message of Msg. |
fmt_expires/1 | Format one of our 'expires' dates into a string telling how far in the future the 'expires' time is. |
form_checkboxes/3 | Create checkboxes for every entry in Fields. |
get_checkbox_input/2 | Check which of the HTML variables 'listed' in In that are set in A, and return a list of the atoms in Fields that are set. |
get_user_addresses/2 | Fetch all addresses for a user. |
get_var/2 | Get variable Name content. |
get_var_int/2 | Like get_var/2 but converts the result to an integer. |
get_yxa_application_node/0 | Get name of incomingproxy node. |
hidden_inputs/1 | Produce a list of input fields of type 'hidden'. |
make_radio_input/4 | Return a Yaws HTML construct of a radio button input. |
script_output/1 | |
user_exists/2 | Check if user User exists in the Mnesia userdb. |
error(Msg) -> HTML
Create a red error message of Msg.
fmt_expires(In) -> HTML
Format one of our 'expires' dates into a string telling how far in the future the 'expires' time is.
form_checkboxes(A, In, List) -> HTML
Create checkboxes for every entry in Fields. Example : In = [foo] List = {"base", [foo, bar]} Outputs : checkbox "base.foo", checked checkbox "base.bar", not checked
get_checkbox_input(A, In) -> [atom()]
Check which of the HTML variables 'listed' in In that are set in A, and return a list of the atoms in Fields that are set. Example : VarName = "base" Fields = [foo, bar] returns [foo] if "base.foo" is set to "true", but "base.bar" is not.
get_user_addresses(User, Node) -> [string()]
Fetch all addresses for a user. For legacy reasons, addresses are called numbers in the Mnesia backend.
get_var(A, Name) -> {ok, Value} | undefined
Get variable Name content. First look for a URL variable, and if that is not found and this is a POST, look for a posted variable.
get_var_int(A, Name) -> {ok, Int}
throws {error, Reason}
Like get_var/2 but converts the result to an integer.
get_yxa_application_node() -> Nodename
Get name of incomingproxy node. Per default we do this by figuring out our local hostname, and prepending it with "incomingproxy@". Patch this function if you want to run your web interface on another host than your incomingproxy (NOTE: you MUST make sure the nodes can talk to each other through distributed Erlang).
hidden_inputs(In) -> Out
Produce a list of input fields of type 'hidden'.
make_radio_input(A, Name, Default, In) -> {ok, HTML}
Return a Yaws HTML construct of a radio button input.
script_output(In) -> EHTML
user_exists(User, Node) -> true | false
throws {error, Reason}
Check if user User exists in the Mnesia userdb.
Generated by EDoc, Oct 17 2007, 16:48:28.