本文整理汇总了PHP中parse_bool函数的典型用法代码示例。如果您正苦于以下问题:PHP parse_bool函数的具体用法?PHP parse_bool怎么用?PHP parse_bool使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了parse_bool函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: show_nav
function show_nav()
{
$config = get_config();
$master_url = parse_config($config, "<master_url>");
$no_computing = parse_config($config, "<no_computing>");
$no_web_account_creation = parse_bool($config, "no_web_account_creation");
echo "<div class=\"mainnav\">\n <h2 class=headline>About " . PROJECT . "</h2>\n ";
if ($no_computing) {
echo "\n XXX is a research project that uses volunteers\n to do research in XXX.\n ";
} else {
echo "\n XXX is a research project that uses Internet-connected\n computers to do research in XXX.\n You can participate by downloading and running a free program\n on your computer.\n ";
}
echo "\n <p>\n XXX is based at \n [describe your institution, with link to web page]\n <ul>\n <li> [Link to page describing your research in detail]\n <li> [Link to page listing project personnel, and an email address]\n </ul>\n <h2 class=headline>Join " . PROJECT . "</h2>\n <ul>\n ";
if ($no_computing) {
echo "\n <li> <a href=\"create_account_form.php\">Create an account</a>\n ";
} else {
echo "\n <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n <li> This project uses BOINC.\n If you're already running BOINC, select Add Project.\n If not, <a target=\"_new\" href=\"http://boinc.berkeley.edu/download.php\">download BOINC</a>.\n <li> When prompted, enter <br><b>" . $master_url . "</b>\n ";
if (!$no_web_account_creation) {
echo "\n <li> If you're running a command-line version of BOINC,\n <a href=\"create_account_form.php\">create an account</a> first.\n ";
}
echo "\n <li> If you have any problems,\n <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n ";
}
echo "\n </ul>\n\n <h2 class=headline>Returning participants</h2>\n <ul>\n ";
if ($no_computing) {
echo "\n <li><a href=\"bossa_apps.php\">Do work</a>\n <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n <li><a href=\"team.php\">Teams</a> - create or join a team\n ";
} else {
echo "\n <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n <li><a href=server_status.php>Server status</a>\n <li><a href=\"team.php\">Teams</a> - create or join a team\n <li><a href=\"cert1.php\">Certificate</a>\n <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n ";
}
echo "\n </ul>\n <h2 class=headline>" . tra("Community") . "</h2>\n <ul>\n <li><a href=\"profile_menu.php\">" . tra("Profiles") . "</a>\n <li><a href=\"user_search.php\">User search</a>\n <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n <li><a href=\"forum_help_desk.php\">" . tra("Questions and Answers") . "</a>\n <li><a href=\"stats.php\">Statistics</a>\n <li><a href=language_select.php>Languages</a>\n </ul>\n </div>\n ";
}
示例2: show_nav
function show_nav()
{
$config = get_config();
$master_url = parse_config($config, "<master_url>");
$no_computing = parse_config($config, "<no_computing>");
$no_web_account_creation = parse_bool($config, "no_web_account_creation");
echo "<div class=\"mainnav\">\n\n <h2 class=headline>Returning participants</h2>\n <ul>\n ";
if ($no_computing) {
echo "\n <li><a href=\"bossa_apps.php\">Do work</a>\n <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n <li><a href=\"team.php\">Teams</a> - create or join a team\n ";
} else {
echo "\n <li><h3 class=headline > <a href=\"home.php\">Your account</a> - Create/List Tasks , stats, preferences </h3>\n <li><a href=server_status.php>Server status</a>\n <li><a href=\"team.php\">Teams</a> - create or join a team\n <li><a href=\"cert1.php\">Certificate</a>\n <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n ";
}
echo "\n </ul>";
echo "<div class=\"mainnav\">\n <h2 class=headline>About " . PROJECT . "</h2>\n ";
if ($no_computing) {
echo "\n " . SHORT_NAME . " is a research project that uses volunteers\n to do research in Electromechanical Activity in the Human Heart.\n ";
} else {
echo "\n " . SHORT_NAME . " is a research project that uses Internet-connected\n computers to do research in Electromechanical Activity in the Human Heart.\n You can participate by downloading and running a free program\n on your computer.\n ";
}
echo "\n <p>\n " . SHORT_NAME . " is based at \n USJ, Universidad San Jorge <a href=\"http://www.usj.es\">www.usj.es</a>\n <ul>\n <li> Code (and request modificacions) is available for web interface at <a href=\"https://github.com/rampxxxx/em\">https://github.com/rampxxxx/em</a>\n <li> Code (and request modificacions) is available for boinc daemons at <a href=\"https://github.com/rampxxxx/boinc\">https://github.com/rampxxxx/boinc</a>\n <li> Code (and request modificacions) is available for EM models at <a href=\"https://github.com/rampxxxx/TestEM\">https://github.com/rampxxxx/TestEM</a>\n </ul>\n <h2 class=headline>Join " . PROJECT . "</h2>\n <ul>\n ";
if ($no_computing) {
echo "\n <li> <a href=\"create_account_form.php\">Create an account</a>\n ";
} else {
echo "\n <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n <li> This project uses BOINC.\n If you're already running BOINC, select Add Project.\n If not, <a target=\"_new\" href=\"http://boinc.berkeley.edu/download.php\">download BOINC</a>.\n <li> When prompted, enter <br><b>" . $master_url . "</b>\n ";
if (!$no_web_account_creation) {
echo "\n <li> If you're running a command-line version of BOINC,\n <a href=\"create_account_form.php\">create an account</a> first.\n ";
}
echo "\n <li> If you have any problems,\n <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n ";
}
echo "\n </ul>";
echo "\n <h2 class=headline>" . tra("Community") . "</h2>\n <ul>\n <li><a href=\"profile_menu.php\">" . tra("Profiles") . "</a>\n <li><a href=\"user_search.php\">User search</a>\n <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n <li><a href=\"forum_help_desk.php\">" . tra("Questions and Answers") . "</a>\n <li><a href=\"stats.php\">Statistics</a>\n <li><a href=language_select.php>Languages</a>\n </ul>\n </div>\n ";
}
示例3: parse_boolint
function parse_boolint($xml, $tag)
{
$x = parse_bool($xml, $tag);
if ($x) {
return 1;
}
return 0;
}
示例4: reg_form
function reg_form()
{
$config = get_config();
$disable_acct = parse_bool($config, "disable_account_creation");
page_head("Register");
start_table();
echo "<tr><td>";
echo "<h3>Create an account</h3>";
create_account_form(0, "download.php");
echo "</td><td>";
echo "<h3>If you already have an account, log in</h3>";
login_form("download.php");
echo "</td></tr>";
end_table();
page_tail();
}
示例5: show_nav
function show_nav()
{
$config = get_config();
$master_url = parse_config($config, "<master_url>");
$no_computing = parse_config($config, "<no_computing>");
$no_web_account_creation = parse_bool($config, "no_web_account_creation");
$disable_acct = parse_bool($config, "disable_account_creation");
echo "<div class=\"mainnav\">\n <h2 class=headline>About " . PROJECT . "</h2>\n ";
if ($no_computing) {
echo "\n XXX is a research project that uses volunteers\n to do research in XXX.\n ";
} else {
echo "\n XXX is a research project that uses Internet-connected\n computers to do research in XXX.\n You can participate by downloading and running a free program\n on your computer.\n ";
}
echo "\n <p>\n XXX is based at \n [describe your institution, with link to web page]\n <ul>\n <li> [Link to page describing your research in detail]\n <li> [Link to page listing project personnel, and an email address]\n </ul>\n <h2 class=headline>Participate</h2>\n <ul>\n ";
if ($no_computing) {
if (!$no_web_account_creation && !$disable_acct) {
echo "\n <li> <a href=\"create_account_form.php\">Create an account</a>\n ";
} else {
echo "<li> This project is not currently accepting new accounts.";
}
} else {
echo "\n <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n ";
if (0) {
echo "<li>";
show_button("register.php", "Join", null, "btn btn-green");
} else {
echo "<li> <a href=http://boinc.berkeley.edu/download.php>Download</a> and run BOINC.\n <li> Choose Add Project\n ";
}
echo "\n <li> If you have any problems,\n <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n ";
}
echo "\n </ul>\n\n <h2 class=headline>Returning participants</h2>\n <ul>\n <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n ";
if (!$no_computing) {
echo "\n <li><a href=server_status.php>Server status</a>\n <li><a href=\"cert1.php\">Certificate</a>\n <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n ";
}
if (!DISABLE_TEAMS) {
echo "\n <li><a href=\"team.php\">Teams</a> - create or join a team\n ";
}
echo "\n </ul>\n <h2 class=headline>" . tra("Community") . "</h2>\n <ul>\n ";
if (!DISABLE_PROFILES) {
echo "\n <li><a href=\"profile_menu.php\">" . tra("Profiles") . "</a>\n ";
}
echo "\n <li><a href=\"user_search.php\">User search</a>\n <li><a href=ffmail_form.php>Share</a>\n ";
if (!DISABLE_FORUMS) {
echo "\n <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n <li><a href=\"forum_help_desk.php\">" . tra("Questions and Answers") . "</a>\n ";
}
echo "\n <li><a href=\"stats.php\">Statistics</a>\n <li><a href=language_select.php>Languages</a>\n </ul>\n </div>\n ";
}
示例6: show_nav
function show_nav()
{
$config = get_config();
$master_url = parse_config($config, "<master_url>");
$no_computing = parse_config($config, "<no_computing>");
$no_web_account_creation = parse_bool($config, "no_web_account_creation");
$user = get_logged_in_user(false);
echo "<div class=\"mainnav\">\n <h2 class=headline>About " . PROJECT . "</h2>\n ";
echo "\n The Quake Catcher Network (QCN) is a research project that uses Internet-connected\n computers to do research, education, and outreach in seismology.\n You can participate by downloading and running a free program\n on your computer. Currently only certain Mac (OS X) PPC and Intel laptops are supported --\n recent ones which have a built-in accelerometer. You can also buy an external USB accelerometer.\n <p>\n QCN is based at the Stanford University School of Earth Sciences.\n <ul>\n <li> <A HREF=\"" . BASEURL . "/index.php\">Quake Catcher Network Home Page</A>\n <li> <A HREF=\"" . BASEURL . "/about-qcn/contact-us\">Project Personnel</A>\n </ul>\n ";
if ($no_computing) {
echo "\n <li> <a href=\"create_account_form.php\">Create an account</a>\n ";
} else {
echo "\n <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n <li> This project uses BOINC.\n If you're already running BOINC, select Add Project.\n If not, <a target=\"_new\" href=\"http://boinc.berkeley.edu/download.php\">download BOINC</a>.\n <li> When prompted, enter <br><b>" . $master_url . "</b>\n ";
if (!$no_web_account_creation) {
echo "\n <li> If you're running a command-line version of BOINC,\n <a href=\"create_account_form.php\">create an account</a> first.\n ";
}
echo "\n <li> If you have any problems,\n <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n ";
}
echo "\n </ul><BR><p>\n\n <h2 class=headline>Returning participants</h2>\n <ul>\n ";
if ($no_computing) {
echo "\n <li><a href=\"bossa_apps.php\">Do work</a>\n <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n <li><a href=\"team.php\">Teams</a> - create or join a team\n ";
} else {
echo "\n <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n <li><a href=server_status.php>Server status</a>\n <li><a href=\"team.php\">Teams</a> - create or join a team\n <li><a href=\"cert1.php\">Certificate</a>\n <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n ";
}
echo "\n </ul>\n <h2 class=headline>" . tra("Community") . "</h2>\n <ul>\n <li><a href=\"user_search.php\">User search</a>\n <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n <li><a href=\"stats.php\">Statistics</a>\n <li><a href=language_select.php>Languages</a>\n </ul>\n ";
// CMC changed to forum prefs 4th bit
if (qcn_admin_user_auth($user)) {
// defined in project/project.inc
echo "\n <h2>" . tra("Extra Links") . "</h2>\n <ul>\n <li><a href=\"trdl.php\">" . tra("Trigger Search/Upload/Download Page") . "</a>\n <li><a href=\"ramp.php\">" . tra("View RAMP Signups") . "</a>\n <li><a href=\"" . BASEURL . "/sensor/todo\">" . tra("To-Do List") . "</a></ul>";
//if ($user->id == 15) {
// check for db replication timestamp
#$kewfile = BASEPATH . "/boinc/sensor/html/user/max.txt";
#if (file_exists($kewfile) && ($handle = fopen($kewfile, 'r'))) {
# $output = fgets($handle); // skip first line
# $output = fgets($handle); fclose($handle);
# echo " <li>Kew Sync Diff (seconds): " . $output . "<BR>(should be a small number else server is down) <BR>";
# } else {
# echo " <li>No Replication Sync File on Kew - Better Check!";
# }
}
qcn_show_map();
echo " </div>";
}
示例7: show_download_page
function show_download_page()
{
page_head("Download required software");
$config = get_config();
$need_vbox = parse_bool($config, "need_vbox");
$mcv = parse_config($config, "<min_core_client_version>");
$dlv = "BOINC";
$dl = "BOINC";
if ($mcv) {
$dlv .= " version " . version_string_maj_min_rel($mcv) . " or later";
}
$verb = "this is";
if ($need_vbox) {
$dl .= " and VirtualBox";
$dlv .= " and VirtualBox";
$verb = "these are";
}
echo "To participate in " . PROJECT . ", {$dlv} must be installed.\n <p>\n If {$verb} already installed, <a href=download.php?action=installed>click here</a>. Otherwise\n <p>\n ";
show_button("download.php?action=download", "Download {$dl}");
echo "<p>\n When the download is finished,\n open the downloaded file to install BOINC.\n ";
page_tail();
}
示例8: array
$openid->required = array('namePerson/friendly', 'contact/email');
$openid->optional = array('contact/country/home');
header('Location: ' . $openid->authUrl());
}
} elseif ($openid->mode == 'cancel') {
echo 'User has canceled authentication!';
} else {
echo 'User ' . ($openid->validate() ? $openid->identity . ' has ' : 'has not ') . 'logged in.';
//print_r($openid->getAttributes());
// Create the user in the DB
$data = $openid->getAttributes();
$email_addr = $data['contact/email'];
$email_addr = strtolower($email_addr);
$user_name = $data['namePerson/friendly'];
$config = get_config();
if (parse_bool($config, "disable_account_creation")) {
page_head("Account creation is disabled");
echo "\n <h3>Account creation is disabled</h3>\n Sorry, this project has disabled the creation of new accounts.\n Please try again later.\n ";
exit;
}
// see whether the new account should be pre-enrolled in a team,
// and initialized with its founder's project prefs
//
//$teamid = post_int("teamid", true);
//if ($teamid) {
// $team = lookup_team($teamid);
// $clone_user = lookup_user_id($team->userid);
// if (!$clone_user) {
// echo "User $userid not found";
// exit();
// }
示例9: check_get_args
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
require_once "../inc/db.inc";
require_once "../inc/util.inc";
require_once "../inc/account.inc";
check_get_args(array("next_url"));
$next_url = sanitize_local_url(get_str('next_url', true));
$next_url = urldecode($next_url);
$u = "login_form.php?next_url=" . $next_url;
redirect_to_secure_url($u);
$user = get_logged_in_user(false);
if ($user) {
page_head("Already logged in");
row2("You are logged in as {$user->name}", ". <a href=\"logout.php?" . url_tokens($user->authenticator) . "\">Log out</a>");
page_tail();
exit;
}
page_head(tra("Log in"));
if (0) {
echo '
<a href="openid_login.php?openid_identifier=https://www.google.com/accounts/o8/id"><img src=img/google-button.png></a>
<a href="openid_login.php?openid_identifier=http://yahoo.com"><img src=img/yahoo-button.png></a>
<br>
';
}
login_form($next_url);
$config = get_config();
if (!parse_bool($config, "disable_account_creation") && !parse_bool($config, "no_web_account_creation")) {
echo tra("or %1create an account%2.", "<a href=\"create_account_form.php?next_url={$next_url}\">", "</a>");
}
echo "\n <script type=\"text/javascript\">\n document.f.email_addr.focus();\n </script>\n";
page_tail();
示例10: check_get_args
//
// BOINC is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
// See the GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
// Show results with pending credit for a user
require_once "../inc/util.inc";
require_once "../inc/boinc_db.inc";
require_once "../inc/xml.inc";
check_get_args(array("format", "authenticator"));
BoincDb::get(true);
$config = get_config();
if (!parse_bool($config, "show_results")) {
error_page("This feature is turned off temporarily");
}
$format = get_str("format", true);
if ($format == "xml") {
xml_header();
$auth = BoincDb::escape_string(get_str('authenticator'));
$user = BoincUser::lookup("authenticator='{$auth}'");
if (!$user) {
echo "<error>" . xml_error(-136) . "</error>\n";
exit;
}
$sum = 0;
echo "<pending_credit>\n";
$results = BoincResult::enum("userid={$user->id} AND (validate_state=0 OR validate_state=4) AND claimed_credit > 0");
foreach ($results as $result) {
示例11: get_config
// under the terms of the GNU Lesser General Public License
// as published by the Free Software Foundation,
// either version 3 of the License, or (at your option) any later version.
//
// BOINC is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
// See the GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
// This file allows people to rate posts in a thread
require_once '../inc/forum.inc';
require_once '../inc/util.inc';
$config = get_config();
if (parse_bool($config, "no_forum_rating")) {
page_head(tra("Rating offline"));
echo tra("This function is turned off by the project");
page_tail();
exit(0);
}
if (!empty($_GET['post'])) {
$postId = get_int('post');
$choice = post_str('submit', true);
$rating = post_int('rating', true);
if (!$choice) {
$choice = get_str('choice', true);
}
if ($choice == SOLUTION or $choice == "p") {
$rating = 1;
} else {
示例12: check_get_args
// You should have received a copy of the GNU Lesser General Public License
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
require_once '../inc/boinc_db.inc';
require_once '../inc/util.inc';
require_once '../inc/account.inc';
require_once '../inc/countries.inc';
require_once '../inc/translation.inc';
require_once '../inc/recaptchalib.php';
check_get_args(array("next_url", "teamid"));
$next_url = sanitize_local_url(get_str('next_url', true));
redirect_to_secure_url("create_account_form.php?next_url={$next_url}");
$config = get_config();
if (parse_bool($config, "disable_account_creation")) {
error_page("This project is not accepting new accounts");
}
if (parse_bool($config, "no_web_account_creation")) {
error_page("This project has disabled Web account creation");
}
page_head(tra("Create an account"), null, null, null, recaptcha_get_head_extra());
if (!no_computing()) {
echo "<p>\n <b>" . tra("NOTE: If you use the BOINC Manager, don't use this form. Just run BOINC, select Add Project, and enter an email address and password.") . "</b></p>\n ";
}
$teamid = get_int("teamid", true);
if ($teamid) {
$team = BoincTeam::lookup_id($teamid);
$user = BoincUser::lookup_id($team->userid);
if (!$user) {
error_page("Team {$team->name} has no founder");
$teamid = 0;
} else {
echo "<b>" . tra("This account will belong to the team %1 and will have the project preferences of its founder.", "<a href=\"team_display.php?teamid={$team->id}\">{$team->name}</a>") . "</b><p>";
示例13: check_get_args
check_get_args(array("next_url", "teamid"));
$next_url = sanitize_local_url(get_str('next_url', true));
if (defined('SECURE_URL_BASE') && strstr(SECURE_URL_BASE, "https://") && !$_SERVER['HTTPS']) {
Header("Location: " . SECURE_URL_BASE . "/create_account_form.php?next_url={$next_url}");
exit;
}
page_head(tra("Create an account"), null, null, null, IE_COMPAT_MODE);
$config = get_config();
if (parse_bool($config, "disable_account_creation")) {
echo "\n <h1>" . tra("Account creation is disabled") . "</h1>\n <p>" . tra("Account creation is currently disabled. Please try again later.") . "</p>\n ";
page_tail();
exit;
}
// CMC check for RAMP
$isramp = strstr($next_url, "ramp");
$nwac = parse_bool($config, "no_web_account_creation");
if (!$wac && !$isramp && !no_computing()) {
echo "<p>\n <b>" . tra("NOTE: If you use the BOINC Manager, don't use this form. Just run BOINC, select Add Project, and enter an email address and password.") . "</b></p>\n ";
}
echo "\n <p>\n <form action=\"create_account_action.php\" method=\"post\">\n <input type=hidden name=next_url value=\"{$next_url}\">\n";
$teamid = get_int("teamid", true);
if ($teamid) {
$team = lookup_team($teamid);
$user = lookup_user_id($team->userid);
if (!$user) {
echo "No such user";
} else {
echo "<b>" . tra("This account will belong to the team %1 and will have the project preferences of its founder.", "<a href=\"team_display.php?teamid={$team->id}\">{$team->name}</a>") . "</b><p>";
echo "\n <input type=\"hidden\" name=\"teamid\" value=\"{$teamid}\">\n ";
}
}
示例14: page_head
}
page_head(tra("Workunit %1", $wuid));
$app = BoincApp::lookup_id($wu->appid);
start_table();
row2(tra("name"), $wu->name);
row2(tra("application"), $app->user_friendly_name);
row2(tra("created"), time_str($wu->create_time));
if ($wu->canonical_resultid) {
row2(tra("canonical result"), "<a href=result.php?resultid={$wu->canonical_resultid}>{$wu->canonical_resultid}</a>");
row2(tra("granted credit"), format_credit($wu->canonical_credit));
}
// if app is using adaptive replication and no canonical result yet,
// don't show anything more
// (so that bad guys can't tell if they have an unreplicated job)
$config = get_config();
if ($app->target_nresults > 0 && !$wu->canonical_resultid && !$wu->error_mask && !parse_bool($config, "dont_suppress_pending")) {
row2(tra("Tasks in progress"), tra("suppressed pending completion"));
end_table();
} else {
row2(tra("minimum quorum"), $wu->min_quorum);
row2(tra("initial replication"), $wu->target_nresults);
row2(tra("max # of error/total/success tasks"), "{$wu->max_error_results}, {$wu->max_total_results}, {$wu->max_success_results}");
if ($wu->error_mask) {
row2(tra("errors"), wu_error_mask_str($wu->error_mask));
}
if ($wu->need_validate) {
row2(tra("validation"), tra("Pending"));
}
if (function_exists('project_workunit')) {
project_workunit($wu);
}
示例15: page_head
// under the terms of the GNU Lesser General Public License
// as published by the Free Software Foundation,
// either version 3 of the License, or (at your option) any later version.
//
// BOINC is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
// See the GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
require_once '../inc/util.inc';
require_once '../inc/stats_sites.inc';
page_head(tra('Statistics and leaderboards'));
check_get_args(array());
$credit_by_app = parse_bool(get_config(), "credit_by_app");
start_table();
echo "\n <tr><td>" . tra("Statistics for %1", PROJECT) . ":\n <ul>\n <li><a href=\"top_users.php\">" . tra("Top participants") . "</a>\n";
if ($credit_by_app) {
echo "<ul><li><a href=per_app_list.php>Per application</a></ul>\n";
}
if (!DISABLE_TEAMS) {
echo "\n <li><a href=\"top_teams.php\">" . tra("Top teams") . "</a>\n ";
if ($credit_by_app) {
echo "<ul><li><a href=per_app_list.php?is_team=1>Per application</a></ul>\n";
}
}
echo "\n<li><a href=\"top_hosts.php\">" . tra("Top computers") . "</a>\n<li><a href=\"gpu_list.php\">" . tra("GPU models") . "</a>\n<li><a href=\"cpu_list.php\">" . tra("CPU models") . "</a>\n</ul>\n\n<p>" . tra("More detailed statistics for %1 and other BOINC-based projects are available at several web sites:", PROJECT);
shuffle($stats_sites);
site_list($stats_sites);
echo tra("You can also get your current statistics in the form of a \"signature image\":");