Implement FreeBSD community portal (FCP5) - private message
completed by: Nagato Yuki
mentors: Wojciech A. Koszek, Jakub Klama
Description of a task
This is a research task. It may or may not be deployed in production systems. No effort has been made to coordinate this task with the FreeBSD Core Team.
For this task you assume users are collected in a simple: ID, NAME, MSG_ID, MESSAGE_TEXT SQL table. Your task is to implement 'Private message' functionality -- ability for user X to send a private message to user Y.
For simplicity, you can assume user X is a source user and his ID is 123 and is present in variable $user_src_id:
$user_src_id = 123;
For simplicity, you can assume user Y is a destination user and his ID is 999 and is present in variable $user_dest_id:
$user_dest_id = 999.
Alternatively, you can make destination ID be fetched from the WWW form (this is harder, but preferred). No validation for IDs must be done for simplicity.
Script must be able to (1) present HTML form with message title, text and 'Send' button (2) accept UTF-8 formatted input (3) submit it to the destination user's table.
Please follow Steve's Krug "Don't make me think" principles as well as Jacob Nielsen's useability rules when designing the WWW form. In other words: make it as minimalistic and simple as possible.
Technology choice is up to you, but PHP is preferred (Facebook API is in PHP at least). No framework is required to accomplish the task; however, frameworks aren't prohibited. In case of not using any framework, please follow the MVC design principles.