3 function handle_showstream() {
5 $user_name = $_REQUEST['profile'];
6 $profile = Profile::staticGet('nickname', $user_name);
9 showstream_no_such_user();
12 $user = User::staticGet($profile->id);
16 showstream_no_such_user();
19 if ($profile->id == current_user()->id) {
20 showstream_notice_form();
23 showstream_show_profile($profile);
25 $notice = DB_DataObject::factory('notice');
26 $notice->profile_id = $profile->id;
27 $notice->limit(1, 10);
31 while ($notice->fetch()) {
32 showstream_show_notice($notice);
36 function showstream_no_such_user() {
37 common_user_error('No such user');
40 function showstream_notice_form() {
44 function showstream_show_profile($profile) {