## Get a database connection $db = new DB_DocsWell(); // Check if there was a submission $reg = 0; while (is_array($HTTP_POST_VARS) && (list($key, $val) = each($HTTP_POST_VARS))) { switch ($key) { case "register": // Register a new user $username = trim($username); $password = trim($password); $cpassword = trim($cpassword); $realname = trim($realname); $email_usr = trim($email_usr); if (empty($username) || empty($password) || empty($cpassword) || empty($email_usr)) { // Do we have all necessary data? $be->box_full($t->translate("Error"), $t->translate("Please enter") . " <b>" . $t->translate("Username") . "</b>, <b>" . $t->translate("Password") . "</b> " . $t->translate("and") . " <b>" . $t->translate("E-Mail") . "</b>!"); break; } if (strcmp($password, $cpassword)) { // password are identical? $be->box_full($t->translate("Error"), $t->translate("The passwords are not identical") . ". " . $t->translate("Please try again") . "!"); break; } /* Does the user already exist? NOTE: This should be a transaction, but it isn't... */ $db->query("select * from auth_user where username='******'"); if ($db->nf() > 0) { $be->box_full($t->translate("Error"), $t->translate("User") . " <B>{$username}</B> " . $t->translate("already exists") . "!<br>" . $t->translate("Please select a different Username") . "."); break; } // Create a uid and insert the user...
require "include/header.inc"; $bx = new box("100%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); start_content(); // When there's a search for a blank line, we look for "xxxxxxxx" if (!isset($search) || $search == "") { $search = "xxxxxxxx"; } // $iter is a variable for printing the Top Statistics in steps of 10 apps if (!isset($iter)) { $iter = 0; } $iter *= 10; // We need to know the total number of apps $db->query("SELECT * FROM description WHERE project_title LIKE '%{$search}%'"); if ($db->num_rows() == 0) { $bx->box_full($t->translate("Search"), $t->translate("No projects found")); } else { while ($db->next_record()) { $numiter = ($db->f("COUNT(*)") - 1) / 10; $query = "SELECT * FROM description,auth_user WHERE " . "description.proid='" . $db->f("proid") . "' AND " . "description.description_user=auth_user.username " . "AND description.status > '0' GROUP BY " . "description.proid"; lib_show_description($query); if ($numiter > 1) { $url = "search.php"; $urlquery = array("search" => $search, "by" => $by); show_more($iter, $numiter, $url, $urlquery); } } } end_content(); require "include/footer.inc"; page_close();
# $Id: watch.php,v 1.9 2004/03/02 09:22:58 helix Exp $ # ###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "DevCounter_Session", "auth" => "DevCounter_Auth", "perm" => "DevCounter_Perm")); require "./include/header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); $db2 = new DB_DevCounter(); $db3 = new DB_DevCounter(); ?> <!-- content --> <?php if ($config_perm_watch != "all" && (!isset($perm) || !$perm->have_perm($config_perm_watch))) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { $username = $auth->auth["uname"]; htmlp_form_action("watchset.php", array(), "POST"); echo "\n"; $db3->query("SELECT * FROM prog_ability_watch WHERE username='******'"); if ($db3->next_record()) { $exists = 1; } else { $exists = 0; } $bx->box_begin(); $bx->box_title($t->translate("Set your Developers Watch")); $bx->box_body_begin(); echo "<table border=0 width=100% align=center cellspacing=0 cellpadding=3>\n"; echo "<tr><td align=center><B>" . $t->translate("Which programming experiences you like to watch?") . "</B></td></tr><tr><td>\n";
## Get a database connection $db = new DB_SourceLines(); // Check if there was a submission while (is_array($HTTP_POST_VARS) && (list($key, $val) = each($HTTP_POST_VARS))) { switch ($key) { case "u_edit": // Change user parameters if ($auth->auth["uid"] == $u_id) { // user changes his own account $password = trim($password); $cpassword = trim($cpassword); $realname = trim($realname); $email_usr = trim($email_usr); if (strcmp($password, $cpassword)) { // password are identical? $be->box_full($t->translate("Error"), $t->translate("The passwords are not identical") . ". " . $t->translate("Please try again") . "!"); break; } $query = "UPDATE auth_user SET password='******', realname='{$realname}', email_usr='******', modification_usr=NOW() WHERE user_id='{$u_id}'"; $db->query($query); if ($db->affected_rows() == 0) { $be->box_full($t->translate("Error"), $t->translate("Change User Parameters failed") . ":<br>{$query}"); break; } $bi->box_full($t->translate("Change User Parameters"), $t->translate("Password and/or E-Mail Address of") . " <b>" . $auth->auth["uname"] . "</b> " . $t->translate("is changed") . "."); if ($ml_notify) { $message = "Username: "******"uname"] . "\n"; $message .= "Realname: {$realname}\n"; $message .= "E-Mail: {$email_usr}\n"; mailuser("admin", "User parameters has changed", $message); }
###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "DocsWell_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { @page_close(); page_open(array("sess" => "DocsWell_Session", "auth" => "DocsWell_Auth", "perm" => "DocsWell_Perm")); } require "./include/header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($config_perm_admformat != "all" && (!isset($perm) || !$perm->have_perm($config_perm_admformat))) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { if (isset($format) && !empty($format)) { // Look if Format is already in table $db->query("SELECT * FROM FORMATDEF WHERE NAME='{$format}'"); if ($db->num_rows() > 0) { if (isset($new_format)) { // If format in database and a new name is given, then rename if (!empty($new_format)) { $db->query("UPDATE FORMATDEF SET NAME='{$new_format}' WHERE NAME='{$format}'"); if ($db->affected_rows() == 1) { $bx->box_full($t->translate("Administration"), $t->translate("Format") . " {$format} " . $t->translate("has been renamed to") . " {$new_format}"); } } else { // Format is a blank line $be->box_full($t->translate("Error"), $t->translate("Format name not specified"));
if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "DevCounter_Session", "auth" => "DevCounter_Auth", "perm" => "DevCounter_Perm")); } require "./include/header.inc"; $bx = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php $db->query("SELECT * FROM faq WHERE language='{$la}'"); if ($db->num_rows() > 0) { while ($db->next_record()) { $msg .= "<li><a href=#" . $db->f("faqid") . ">" . $db->f("question") . "</a>"; } $bx->box_full($t->translate("Frequently Asked Questions"), $msg); $db->seek(0); while ($db->next_record()) { echo "<a name=" . $db->f("faqid") . ">\n"; $bx->box_full($t->translate("Question") . ": " . $db->f("question"), "<b>" . $t->translate("Answer") . ":</b> " . $db->f("answer")); } } else { $be->box_full($t->translate("Error"), $t->translate("No Frequently Asked Questions exist")); } ?> <!-- end content --> <?php require "./include/footer.inc"; @page_close();
# the Free Software Foundation; either version 2 or later of the GPL. ###################################################################### page_open(array("sess" => "DocsWell_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { @page_close(); page_open(array("sess" => "DocsWell_Session", "auth" => "DocsWell_Auth", "perm" => "DocsWell_Perm")); } require "header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($config_perm_admtype != "all" && (!isset($perm) || !$perm->have_perm($config_perm_admtype))) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { if (isset($type) && !empty($type)) { // Look if Type is already in table $db->query("SELECT * FROM TYPDEF WHERE NAME='{$type}'"); if ($db->num_rows() > 0) { if (isset($new_type)) { // If type in database and a new name is given, then rename if (!empty($new_type)) { $db->query("UPDATE TYPDEF SET NAME='{$new_type}' WHERE NAME='{$type}'"); if ($db->affected_rows() == 1) { $bx->box_full($t->translate("Administration"), $t->translate("Type") . " {$type} " . $t->translate("has been renamed to") . " {$new_type}"); } } else { // Type is a blank line $be->box_full($t->translate("Error"), $t->translate("Type name not specified"));
page_open(array("sess" => "DevCounter_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "DevCounter_Session", "auth" => "DevCounter_Auth", "perm" => "DevCounter_Perm")); } require "./include/header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); $db2 = new DB_DevCounter(); ?> <!-- content --> <?php $counter = 0; if (empty($auth->auth["uname"])) { $be->box_full($t->translate("Not logged in"), $t->translate("Please login first")); } else { $username = $auth->auth["uname"]; $db->query("SELECT * FROM requests WHERE reqid='{$reqid}' AND username='******'"); if ($db->num_rows() == 1) { $db->next_record(); $bx->box_begin(); $bx->box_title($t->translate("edit request")); $bx->box_body_begin(); htmlp_form_action("req_manage.php", "", "POST"); htmlp_form_hidden("option", "edit"); htmlp_form_hidden("reqid", $reqid); echo $t->translate("Subject") . ":<BR>"; $reqsubject = $db->f("reqsubject"); htmlp_input_text("reqsubject", 50, 75, $reqsubject); htmlp_form_submit($t->translate("Send"), "");
# # $Id: entupd.php,v 1.2 2003/02/25 11:45:44 helix Exp $ # ###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "SourceBiz_Session", "auth" => "SourceBiz_Auth", "perm" => "SourceBiz_Perm")); require "./include/header.inc"; require "./include/entlib.inc"; $bx = new box("100%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($perm->have_perm("user_pending")) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); $auth->logout(); } else { if (isset($id)) { $columns = "*"; $tables = "enterprise"; $where = "enterprise.entid = '{$id}'"; if (!$db->query("SELECT {$columns} FROM {$tables} WHERE {$where}")) { mysql_die($db); } else { $db->next_record(); if ($db->f("user") == $auth->auth["uname"] || $perm->have_perm("admin")) { if (!isset($action)) { entmod($db); } else { $name = trim($name);
$set = "name_pro='{$name_pro}',category_pro='{$category_pro}',description_pro='{$description_pro}',homepage_pro='{$homepage_pro}'"; $where = "proid='{$id}'"; switch ($action) { case "change": $set = $set . ",status_pro='{$status_pro}'"; break; case "delete": $set = $set . ",status_pro='D'"; break; case "undelete": $set = $set . ",status_pro='A'"; break; case "erase": break; default: $be->box_full($t->translate("Error"), $t->translate("No Action specified")); $set = $set . ",status_pro='{$status_pro}'"; break; } if ($action == "erase") { $query = "DELETE FROM {$tables} WHERE {$where}"; } else { $query = "UPDATE {$tables} SET {$set} WHERE {$where}"; } if ($action == "erase" && !$perm->have_perm("admin")) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { if (!$db->query($query)) { mysql_die($db); } else { if ($action == "erase") {
page_open(array("sess" => "DevCounter_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "DevCounter_Session", "auth" => "DevCounter_Auth", "perm" => "DevCounter_Perm")); } require "./include/header.inc"; $bx = new box("100%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); $db2 = new DB_DevCounter(); $db3 = new DB_DevCounter(); ?> <!-- content --> <?php if (empty($auth->auth["uname"])) { $be->box_full($t->translate("Not logged in"), $t->translate("Please login first")); } else { $bx->box_begin(); $bx->box_title($t->translate("Personal Data")); $bx->box_body_begin(); echo "<table border=0 width=100% align=center cellspacing=0 cellpadding=3>\n"; htmlp_form_action("insert.php", "", "POST"); echo "\n"; $username = $auth->auth["uname"]; htmlp_form_hidden("username", $username); echo "<tr><td align=right width=30%>" . $t->translate("Username") . ":</td><td width=70%> {$username}\n"; echo "<tr><td align=right width=30%>" . $t->translate("Nationality") . ":</td><td width=70%>\n"; htmlp_select("nationality"); echo "\n"; select_country(999); htmlp_select_end();
} else { $Cquery .= " where a.STATUS!='D' AND a.KATEGORIE={$kategorie} "; } $where .= " AND a.KATEGORIE={$kategorie} "; $flag = 1; } // We need to know the total number of apps //echo "<br><br><br>$Cquery\n<br><br><br>"; $db->query($Cquery . " AND z.id=a.KATEGORIE "); //echo $Cquery; //echo $Cquery; $db->next_record(); $cnt = $db->f("COUNT(*)"); //echo $cnt."<<<<<<<<<<<<<<<<<<<<<<<"; if ($cnt == 0) { $bx->box_full($t->translate("Search"), $t->translate("No Documents found")); } else { switch ($by) { case "Category": $order = "KategorieName ASC, a.AENDERUNGSDATUM DESC, ID DESC"; break; case "Author": $order = "AutorName ASC, a.AENDERUNGSDATUM DESC, ID DESC"; break; case "Date": $order = "a.AENDERUNGSDATUM DESC, ID DESC"; break; case "Name": $order = "a.TITEL ASC, a.AENDERUNGSDATUM DESC, a.ID DESC"; break; case "Typ":
# This is the index file which shows the recent apps # # This program is free software. You can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 or later of the GPL. ###################################################################### require "include/prepend.php3"; page_open(array("sess" => "SourceAgency_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "SourceAgency_Session", "auth" => "SourceAgency_Auth", "perm" => "SourceAgency_Perm")); } require "include/header.inc"; require "include/refereeslib.inc"; $bx = new box('80%', $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); start_content(); $page = "step4_edit"; if (check_permission($proid, $page)) { top_bar($proid, $page); print $t->translate("Registered developers can offer themselves as referees"); print ".\n<br><p>\n"; $bx->box_full($t->translate("Info box"), $t->translate("If you are a registered developer, you can propose yourself as a referee for this project....")); if (!isset($submit) || empty($submit)) { referees_form($proid); } else { referees_insert($proid, $auth->auth["uname"]); } } end_content(); require "include/footer.inc"; @page_close();
$set = "profile_prf='{$profile_prf}'"; $where = "prfid='{$id}'"; switch ($action) { case "change": $set = $set . ",status_prf='{$status_prf}'"; break; case "delete": $set = $set . ",status_prf='D'"; break; case "undelete": $set = $set . ",status_prf='A'"; break; case "erase": break; default: $be->box_full($t->translate("Error"), $t->translate("No Action specified")); $set = $set . ",status_prf='{$status_prf}'"; break; } if ($action == "erase") { $query = "DELETE FROM {$tables} WHERE {$where}"; } else { $query = "UPDATE {$tables} SET {$set} WHERE {$where}"; } if ($action == "erase" && !$perm->have_perm("admin")) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { if (!$db->query($query)) { mysql_die($db); } else { if ($action == "erase") {
case "Date": default: $by = "Date"; $order = "a.AENDERUNGSDATUM DESC, a.ID DESC"; break; } $limit = "{$iter},10"; $sort = "({$cnt}) " . $t->translate("sorted by") . ": " . "<a href=\"" . $sess->self_url() . $sess->add_query(array("usr" => $usr, "by" => "Date")) . "\">" . $t->translate("Date") . "</a>" . " | <a href=\"" . $sess->self_url() . $sess->add_query(array("usr" => $usr, "by" => "Category")) . "\">" . $t->translate("Category") . "</a>\n" . " | <a href=\"" . $sess->self_url() . $sess->add_query(array("usr" => $usr, "by" => "Typ")) . "\">" . $t->translate("Type") . "</a>\n" . " | <a href=\"" . $sess->self_url() . $sess->add_query(array("usr" => $usr, "by" => "Name")) . "\">" . $t->translate("Title") . "</a>\n"; $bs->box_strip($sort); $query = "SELECT {$columns} FROM {$tables} WHERE {$where} ORDER BY {$order} LIMIT {$limit}"; //echo $query." <br><br>"; docupdate($query); $db->query($query); if ($db->num_rows() < 1) { $msg = $t->translate("No Docs of User exist") . "."; $bx->box_full($t->translate("Docs of User"), $msg); } if ($numiter > 1) { $url = "docbyuser.php"; $urlquery = array("usr" => $usr, "by" => $by); show_more($iter, $numiter, $url, $urlquery); } ?> <!-- end content --> <?php require "footer.inc"; @page_close(); ?>
# # $Id: admdoco.php,v 1.1 2003/11/21 12:55:59 helix Exp $ # ###################################################################### require "include/prepend.php3"; page_open(array('sess' => 'SourceAgency_Session')); if (isset($auth) && !empty($auth->auth['perm'])) { page_close(); page_open(array('sess' => 'SourceAgency_Session', 'auth' => 'SourceAgency_Auth', 'perm' => 'SourceAgency_Perm')); } require 'include/header.inc'; $bx = new box('97%', $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box('80%', $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); start_content(); if ($config_perm_admdoco != 'all' && (!isset($perm) || !$perm->have_perm($config_perm_admdoco))) { $be->box_full($t->translate('Error'), $t->translate('Access denied')); } else { $db->query("SELECT * FROM doco WHERE language='{$la}'"); $bx->box_begin(); $bx->box_title($t->translate('Page Documentation Administration')); $bx->box_body_begin(); $bx->box_columns_begin(2); $bx->box_column('left', '88%', '', $t->translate('Enter a new ' . 'documentation entry ' . 'for a page')); $bx->box_column('right', '12%', '', html_form_action('insdoco.php') . html_form_hidden('create', 1) . html_form_submit($t->translate('Insert'), 'Insert') . html_form_end()); $bx->box_columns_end(); $bx->box_body_end(); $bx->box_end(); while ($db->next_record()) { $bx->box_begin(); $bx->box_title($t->translate('Page') . ': ' . $db->f('page') . ', ' . $t->translate('Header') . ': ' . $db->f('header')); $bx->box_body_begin();
# This program is free software. You can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 or later of the GPL. ###################################################################### require "include/prepend.php3"; page_open(array('sess' => 'SourceAgency_Session')); if (isset($auth) && !empty($auth->auth['perm'])) { page_close(); page_open(array('sess' => 'SourceAgency_Session', 'auth' => 'SourceAgency_Auth', 'perm' => 'SourceAgency_Perm')); } require 'include/header.inc'; $bx = new box('97%', $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box('80%', $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); start_content(); if ($config_perm_admlicens != 'all' && (!isset($perm) || !$perm->have_perm($config_perm_admlicens))) { $be->box_full($t->translate('Error'), $t->translate('Access denied')); } else { if (isset($license) && !empty($license)) { // Look if License is already in table $db->query("SELECT * FROM licenses WHERE license='{$license}'"); if ($db->num_rows() > 0) { if (isset($new_license)) { // If license in database and a new name is given, then rename if (!empty($new_license)) { $db->query("SELECT proid,creation FROM developing WHERE " . "license = '{$license}'"); // All the affected projects are treated as modified // BUT they are assigned to the new license!!!! while ($db->next_record()) { $creation = $db->f('creation'); $proid = $db->f('proid'); $db_rename = new DB_SourceAgency();
$sort = $t->translate("sorted by") . ": " . "<a href=\"" . $sess->url(basename($PHP_SELF)) . $sess->add_query(array("search" => $search, "by" => "Date")) . "\">" . $t->translate("Date") . "</a>" . " | <a href=\"" . $sess->url(basename($PHP_SELF)) . $sess->add_query(array("search" => $search, "by" => "Name")) . "\">" . $t->translate("Name") . "</a>" . " | <a href=\"" . $sess->url(basename($PHP_SELF)) . $sess->add_query(array("search" => $search, "by" => "Contact")) . "\">" . $t->translate("Contact") . "</a>" . " | <a href=\"" . $sess->url(basename($PHP_SELF)) . $sess->add_query(array("search" => $search, "by" => "Supplier")) . "\">" . $t->translate("Supplier") . "</a>\n"; $bs->box_strip($sort); if ($cnt > 0) { $nav = "< <a href=\"" . $sess->url(basename($PHP_SELF)) . $sess->add_query(array("search" => $search, "cnt" => $next_cnt, "by" => $by)) . "\">" . $t->translate("previous") . " {$config_show_solsperpage} " . $t->translate("Solutions") . "</a>"; } else { $nav = "< " . $t->translate("previous") . " {$config_show_solsperpage} " . $t->translate("Solutions"); } $nav .= " | <a href=\"" . $sess->url(basename($PHP_SELF)) . $sess->add_query(array("search" => $search, "by" => $by)) . "\">" . $t->translate("Top") . "</a>"; if ($db->num_rows() >= $config_show_solsperpage) { $nav .= " | <a href=\"" . $sess->url(basename($PHP_SELF)) . $sess->add_query(array("search" => $search, "cnt" => $prev_cnt, "by" => $by)) . "\">" . $t->translate("next") . " {$config_show_solsperpage} " . $t->translate("Solutions") . "</a> >"; } else { $nav .= " | " . $t->translate("next") . " {$config_show_solsperpage} " . $t->translate("Solutions") . " >"; } $bs->box_strip($nav); while ($db->next_record()) { solshow($db); } $bs->box_strip($nav); $bs->box_strip($sort); } else { $be->box_full($t->translate("Attention"), $t->translate("No more Solutions exist")); } $tbf->table_body_column_end(); $tbf->table_row_end(); $tbf->table_end(); ?> <!-- end content --> <?php require "footer.inc"; page_close();
###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "DevCounter_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "DevCounter_Session", "auth" => "DevCounter_Auth", "perm" => "DevCounter_Perm")); } require "./include/header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($config_perm_admuser != "all" && (!isset($perm) || !$perm->have_perm($config_perm_admuser))) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { // Check if there was a submission while (is_array($HTTP_POST_VARS) && (list($key, $val) = each($HTTP_POST_VARS))) { switch ($key) { case "create": // Create a new user if (empty($username) || empty($password) || empty($email_usr)) { // Do we have all necessary data? $be->box_full($t->translate("Error"), $t->translate("Please enter") . " <B>" . $t->translate("Username") . "</B>, <B>" . $t->translate("Password") . "</B> " . $t->translate("and") . " <B>" . $t->translate("E-Mail") . "</B>!"); break; } /* Does the user already exist? NOTE: This should be a transaction, but it isn't... */ $db->query("select * from auth_user where username='******'"); if ($db->nf() > 0) {
<!-- content --> <?php if ($perm->have_perm("admin")) { if (isset($category) && !empty($category)) { $dbcat = new DB_SourceBiz(); // Look if Category is already in table $columns = "*"; $tables = "categories"; $where = "type='{$type}' AND category='{$category}'"; if (!$dbcat->query("SELECT {$columns} FROM {$tables} WHERE {$where}")) { mysql_die($dbcat); } else { switch ($action) { case "ins": if ($dbcat->num_rows() > 0) { $be->box_full($t->translate("Error"), $t->translate("Category") . " {$category} " . $t->translate("already exists")); } else { $set = "type='{$type}',category='{$category}'"; if (!$dbcat->query("INSERT {$tables} SET {$set}")) { mysql_die($dbcat); } else { $bx->box_full($t->translate("Administration"), $t->translate("Category") . " {$category} " . $t->translate("has been added")); } } break; case "ren": if ($dbcat->num_rows() < 1) { $be->box_full($t->translate("Error"), $t->translate("Category") . " {$category} " . $t->translate("does not exist")); } else { $set = "category='{$new_category}'"; $where = "type='{$type}' AND category='{$category}'";
# $Id: cusbyentid.php,v 1.2 2003/02/25 11:45:44 helix Exp $ # ###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "SourceBiz_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "SourceBiz_Session", "auth" => "SourceBiz_Auth", "perm" => "SourceBiz_Perm")); } require "./include/header.inc"; require "./include/entlib.inc"; require "./include/cuslib.inc"; $bx = new box("100%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); $bs = new box("100%", $th_strip_frame_color, $th_strip_frame_width, $th_strip_title_bgcolor, $th_strip_title_font_color, $th_strip_title_align, $th_strip_body_bgcolor, $th_strip_body_font_color, $th_strip_body_align); ?> <!-- content --> <?php if (isset($id)) { entbyentid($db, $id); cusbyentid($db, $id); } else { $be->box_full($t->translate("Error"), $t->translate("No Enterprise ID specified")); } ?> <!-- end content --> <?php require "./include/footer.inc"; page_close();
###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "DocsWell_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { @page_close(); page_open(array("sess" => "DocsWell_Session", "auth" => "DocsWell_Auth", "perm" => "DocsWell_Perm")); } require "./include/header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($config_perm_admuser != "all" && (!isset($perm) || !$perm->have_perm($config_perm_admuser))) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { // Check if there was a submission while (is_array($HTTP_POST_VARS) && (list($key, $val) = each($HTTP_POST_VARS))) { switch ($key) { case "create": // Create a new user if (empty($username) || empty($password) || empty($email_usr)) { // Do we have all necessary data? $be->box_full($t->translate("Error"), $t->translate("Please enter") . " <B>" . $t->translate("Username") . "</B>, <B>" . $t->translate("Password") . "</B> " . $t->translate("and") . " <B>" . $t->translate("E-Mail") . "</B>!"); break; } /* Does the user already exist? NOTE: This should be a transaction, but it isn't... */ $db->query("select * from auth_user where username='******'"); if ($db->nf() > 0) {
$set = "name_cus='{$name_cus}',description_cus='{$description_cus}',homepage_cus='{$homepage_cus}'"; $where = "cusid='{$id}'"; switch ($action) { case "change": $set = $set . ",status_cus='{$status_cus}'"; break; case "delete": $set = $set . ",status_cus='D'"; break; case "undelete": $set = $set . ",status_cus='A'"; break; case "erase": break; default: $be->box_full($t->translate("Error"), $t->translate("No Action specified")); $set = $set . ",status_cus='{$status_cus}'"; break; } if ($action == "erase") { $query = "DELETE FROM {$tables} WHERE {$where}"; } else { $query = "UPDATE {$tables} SET {$set} WHERE {$where}"; } if ($action == "erase" && !$perm->have_perm("admin")) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { if (!$db->query($query)) { mysql_die($db); } else { if ($action == "erase") {
# # This program is free software. You can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 or later of the GPL. ###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "SourceWell_Session", "auth" => "SourceWell_Auth", "perm" => "SourceWell_Perm")); require "./include/header.inc"; $bx = new box("100%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($perm->have_perm("user_pending")) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); $auth->logout(); } else { if (empty($name) || empty($version)) { $be->box_full($t->translate("Error"), $t->translate("Parameter missing")); } else { $status = 'P'; $name = trim($name); $type = trim($type); $version = trim($version); $license = trim($license); $homepage = trim($homepage); $download = trim($download); $changelog = trim($changelog); $rpm = trim($rpm); $deb = trim($deb);
###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "SourceContact_Session", "auth" => "SourceContact_Auth", "perm" => "SourceContact_Perm")); require "./include/header.inc"; require "./include/conlib.inc"; require "./include/clalib.inc"; require "./include/perlib.inc"; $bx = new box("100%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); $bs = new box("100%", $th_strip_frame_color, $th_strip_frame_width, $th_strip_title_bgcolor, $th_strip_title_font_color, $th_strip_title_align, $th_strip_body_bgcolor, $th_strip_body_font_color, $th_strip_body_align); ?> <!-- content --> <?php if ($perm->have_perm("user_pending")) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); $auth->logout(); } else { if (isset($id)) { $salutation_per = trim($salutation_per); $firstname_per = trim($firstname_per); $lastname_per = trim($lastname_per); $grad_per = trim($grad_per); $phone_per = trim($phone_per); $fax_per = trim($fax_per); $email_per = trim($email_per); $homepage_per = trim($homepage_per); if (!empty($homepage_per) && !ereg("^http://", $homepage_per)) { $homepage_per = "http://" . $homepage_per; } $comment_per = trim($comment_per);
if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "DevCounter_Session", "auth" => "DevCounter_Auth", "perm" => "DevCounter_Perm")); } require "./include/header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); $db2 = new DB_DevCounter(); ?> <!-- content --> <?php $counter = 0; $db->query("SELECT * from extra_perms WHERE username='******'"); if ($db->num_rows() == 0) { $be->box_full($t->translate("Error"), $t->translate("Unknown Developer")); } else { $bx->box_begin(); $bx->box_title($t->translate("Compose private message")); $bx->box_body_begin(); htmlp_form_action("pmess_send.php", "", "POST"); htmlp_form_hidden("option", "send"); htmlp_form_hidden("devname", $devname); if (empty($auth->auth["uname"])) { $sender = "-"; htmlp_form_hidden("sender", $sender); echo $t->translate("Your E-Mail") . ":<BR>"; htmlp_form_hidden("pmessto", $devname); htmlp_input_text("email", 50, 75, ""); echo "<BR>\n"; } else {
# # This program is free software. You can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 or later of the GPL. ###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "DocsWell_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { @page_close(); page_open(array("sess" => "DocsWell_Session", "auth" => "DocsWell_Auth", "perm" => "DocsWell_Perm")); } require "./include/header.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php $db->query("UPDATE auth_user SET perms='user' WHERE user_id='{$confirm_hash}'"); if ($db->affected_rows() == 0) { $be->box_full($t->translate("Error"), $t->translate("Verification of Registration failed")); } else { $msg = $t->translate("Your account is now activated. Please login") . "."; $bx->box_full($t->translate("Verification of Registration"), $msg); } ?> <!-- end content --> <?php require "./include/footer.inc"; @page_close();
$bx->box_full($t->translate("Weekly Newsletter"), $t->translate("Newsletter was sent at ") . timestr(time())); break; case "daily": default: mail($ml_newstoaddr, $subj, $msg, "From: {$ml_newsfromaddr}\nReply-To: {$ml_newsreplyaddr}\nX-Mailer: PHP"); $bx->box_full($t->translate("Daily Newsletter"), $t->translate("Newsletter was sent at ") . timestr(time())); break; } } $bx->box_full($subj, "<pre>\n" . htmlentities($msg) . "\n</pre>\n"); ?> <form method="get" action="<?php $sess->pself_url(); ?> "> <?php echo "<input type=\"hidden\" name=\"period\" value=\"{$period}\">\n"; echo "<center><p><input type=\"submit\" name=\"send\" value=\"" . $t->translate("Send newsletter") . "\"></center>\n"; echo "</form>\n"; } else { $be->box_full($t->translate("Error"), $t->translate("No Document found") . "."); } } else { $be->box_full($t->translate("Error"), $t->translate("Access denied") . "."); } ?> <!-- end content --> <?php require "footer.inc"; @page_close();
page_open(array("sess" => "SourceWell_Session")); if (isset($auth) && !empty($auth->auth["perm"])) { page_close(); page_open(array("sess" => "SourceWell_Session", "auth" => "SourceWell_Auth", "perm" => "SourceWell_Perm")); } require "./include/header.inc"; require "./include/cmtlib.inc"; $bx = new box("100%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $bi = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($config_perm_admdate != "all" && (!isset($perm) || !$perm->have_perm($config_perm_admdate))) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); } else { if (!isset($action)) { $action = "check"; } $where = "WHERE status='A'"; if (isset($id)) { $where .= " AND appid='{$id}'"; } // Check application $db->query("SELECT * FROM software {$where}"); // echo"<p>SELECT * FROM software $where\n"; $i = 0; while ($db->next_record()) { $db_appid = $db->f("appid"); $db2 = new DB_SourceWell();
# # $Id: prfadd.php,v 1.2 2003/02/25 11:45:44 helix Exp $ # ###################################################################### require "./include/prepend.php3"; page_open(array("sess" => "SourceBiz_Session", "auth" => "SourceBiz_Auth", "perm" => "SourceBiz_Perm")); require "./include/header.inc"; require "./include/prflib.inc"; $bx = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align); $be = new box("", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align); ?> <!-- content --> <?php if ($perm->have_perm("user_pending")) { $be->box_full($t->translate("Error"), $t->translate("Access denied")); $auth->logout(); } else { // If enterprise id specified if (isset($id)) { // Look if enterprise is already in table $columns = "*"; $tables = "enterprise"; $where = "entid='{$id}'"; if (!$db->query("SELECT {$columns} FROM {$tables} WHERE {$where}")) { mysql_die($db); } else { // If enterprise in table if ($db->next_record()) { // If enterprise owner is logged in user if ($db->f("user") == $auth->auth["uname"] || $perm->have_perm("admin")) {