$no_rows = 1; echo "<H2>No matches found for {$words}</H2>"; echo db_error(); // echo $sql; } else { if ($rows_returned > 25) { $rows = 25; } echo "<H3>Search results for {$words}</H3><P>\n\n"; $title_arr = array(); $title_arr[] = 'Group Name'; $title_arr[] = 'Description'; echo html_build_list_table_top($title_arr); echo "\n"; for ($i = 0; $i < $rows; $i++) { print "<TR BGCOLOR=\"" . html_get_alt_row_color($i) . "\"><TD><A HREF=\"/projects/" . db_result($result, $i, 'unix_group_name') . "/\">" . html_image("images/msg.gif", "10", "12", array("BORDER" => "0")) . highlight_target_words($array, db_result($result, $i, 'group_name')) . "</A>" . req_project_donate(db_result($result, $i, 'group_id')) . "</TD>" . "<TD>" . highlight_target_words($array, db_result($result, $i, 'short_description')) . "</TD></TR>\n"; } echo "</TABLE>\n"; } } else { if ($type_of_search == "people") { /* Query to find users */ // If multiple words, separate them and put LIKE in between $array = explode(" ", $words); $words1 = implode($array, "%' {$crit} user_name LIKE '%"); $words2 = implode($array, "%' {$crit} realname LIKE '%"); $sql = "SELECT user_name,user_id,realname " . "FROM users " . "WHERE ((user_name LIKE '%{$words1}%') OR (realname LIKE '%{$words2}%')) AND (status='A') ORDER BY user_name"; $result = db_query($sql, 26, $offset); $rows = $rows_returned = db_numrows($result);
$html_limit .= '</CENTER></SPAN>'; print $html_limit . "<HR>\n"; // ################################################################# // print actual project listings // note that the for loop starts at 1, not 0 for ($i_proj = 1; $i_proj <= $querytotalcount; $i_proj++) { $row_grp = db_fetch_array($res_grp); // check to see if row is in page range if ($i_proj > ($page - 1) * $TROVE_BROWSELIMIT && $i_proj <= $page * $TROVE_BROWSELIMIT) { $viewthisrow = 1; } else { $viewthisrow = 0; } if ($row_grp && $viewthisrow) { print '<TABLE border="0" cellpadding="0" width="100%"><TR valign="top"><TD colspan="2">'; print "{$i_proj}. <a href=\"/projects/" . strtolower($row_grp['unix_group_name']) . "/\"><B>" . htmlspecialchars($row_grp['group_name']) . "</B></a>" . req_project_donate($row_grp['group_id']); if ($row_grp['short_description']) { print " - " . htmlspecialchars($row_grp['short_description']); } print '<BR> '; // extra description print '</TD></TR><TR valign="top"><TD>'; // list all trove categories trove_getcatlisting($row_grp['group_id'], 1, 0); print '</TD>' . "\n" . '<TD align="right">'; // now the right side of the display print 'Activity Percentile: <B>' . $row_grp['percentile'] . '</B>'; print '<BR>Activity Ranking: <B>' . $row_grp['ranking'] . '</B>'; print '<BR>Register Date: <B>' . date($sys_datefmt, $row_grp['register_time']) . '</B>'; print '</TD></TR>'; /*
if (db_numrows($res_new) > 20) { $rows = 20; } else { $rows = db_numrows($res_new); } print "\t<p><TABLE width=100% cellpadding=0 cellspacing=0 border=0>"; for ($i = 0; $i < $rows; $i++) { $row_new = db_fetch_array($res_new); // don't show releases of projects without short description // 2004-11-16 by helix // avoid duplicates of different file types // 2003-04-25 use release id instead of group id by helix if ($row_new[short_description] && !$G_RELEASE["{$row_new['release_id']}"]) { print "<TR valign=top>"; print "<TD colspan=2>"; print "<A href=\"/projects/{$row_new['unix_group_name']}/\"><B>{$row_new['group_name']}</B></A>" . req_project_donate($row_new[group_id]) . "\n</TD><TD nowrap><I>Released by: <A href=\"/users/{$row_new['user_name']}/\">" . "{$row_new['user_name']}</A></I>" . is_project_donor($row_new[user_id]) . is_user_donor($row_new[user_id]) . req_user_donate($row_new[user_id]) . "</TD></TR>\n"; print "<TR><TD>Module: {$row_new['module_name']}</TD>\n"; print "<TD>Version: {$row_new['release_version']}</TD>\n"; print "<TD>" . date("M d, h:iA", $row_new[release_date]) . "</TD>\n"; print "</TR>"; print "<TR valign=top>"; print "<TD colspan=2> <BR>"; if ($row_new[short_description]) { print "<I>{$row_new['short_description']}</I>"; } else { print "<I>This project has not submitted a description.</I>"; } // print "<P>Release rating: "; // print vote_show_thumbs($row_new[filerelease_id],2); print "</TD>"; print '<TD align=center nowrap border=1>';
$group =& group_get_object($group_id); $HTML->header(array('title' => 'Project Icon Legend')); ?> <h2 align="center">Project Icon Legend</h2> <p>BerliOS Developer uses special icons and markings next to the names of some projects to indicate that they request for contributions. This page provides a legend for those markings: <table border="0" cellpadding="3" cellspacing="5"> <tbody> <tr><td colspan="2"><h3>Icon information for Projects:</h3></td> </tr> <tr><td> </td> <td><b>This page has been generated for:</b> <a href="/projects/<?php print $group->getUnixName(); ?> /"><?php print $group->getPublicName() . " (" . $group->getUnixName() . ")"; ?> </a><?php print req_project_donate($group_id); ?> </td> </tr> <tr><td valign="top"><img src="/images/iconPurpleStar_16x16.png" alt="Project Donate" border="0" height="16" width="16">€</a></td> <td>The icon shown at left, a small purple star with a € sign, designates that this project requests for donations.</td> </tr> </tbody> </table> <?php $HTML->footer(array());
$title_arr = array(); $title_arr[] = 'Project'; $title_arr[] = 'Amount'; $title_arr[] = 'Status'; $title_arr[] = 'Date'; $title_arr[] = 'Comment'; echo html_build_list_table_top($title_arr); echo "\n"; for ($i = 0; $i < $rows; $i++) { print '<tr bgcolor=' . html_get_alt_row_color($i) . '>'; $to_group_id = db_result($res, $i, 'to_group_id'); $res_grp = db_query("SELECT * FROM groups WHERE group_id='" . $to_group_id . "'"); if (db_numrows($res_grp) < 1) { print '<td valign="top">' . $to_group_id . '</td>'; } else { print '<td valign="top"><a href="/projects/' . db_result($res_grp, 0, 'unix_group_name') . '">' . db_result($res_grp, 0, 'group_name') . '</a>' . req_project_donate(db_result($res_grp, 0, 'group_id')) . '</td>'; } print '<td align="right" valign="top">€' . db_result($res, $i, 'amount') . ',00</td>'; print '<td align="center" valign="top">' . db_result($res, $i, 'status') . '</td>'; print '<td align="center" valign="top">' . date($sys_datefmt, db_result($res, $i, 'add_date')) . '</td>'; print '<td valign="top">' . db_result($res, $i, 'comment') . '</td>'; print '</tr>'; } print '</td></tr></table>'; } ?> <h3>My Donations to Developers</h3> <?php $res = db_query("SELECT * FROM user_donors WHERE user_id='" . user_getid() . "'");