GSoC/GCI Archive
Google Code-in 2011 FreeBSD

Implement FreeBSD community portal (FCP4) - groups functionality

completed by: n00l3

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 simple: ID, NAME, SURNAME SQL table. Your task is to implement 'groups' SQL table, where users can get grouped.

Next, you must write simple PHP script which assumes, that variable $user_id holds user ID. For now make it static and equal to 123:
$user_id = 123;

Script must show available groups in three rows: 'Group name', 'Subscribe', 'Unsubscribe'. Group name is always displayed. 'Subscribe' column has buttons with 'Subscribe' label only when user can subscribe. 'Unsubscribe' columnt has buttons with 'Unsubscribe' label only when user can unsubscribe. If the user isn't yet in a group, he can subscribe. User can unsubscribe only when he's already in that group. We keep such a layout for usability reasons. Example:

(please visit for sample SQL 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.