Beispiel #1
0
//Name for Level
$err_message = " Unable to process your request due to the following problems: <br>\n";
$header = "View Abstract";
$accepted_privilegeID_arr = array(2 => "");
$accepted_phaseID_arr = array(2 => "", 3 => "");
authentication($header, $accepted_privilegeID_arr, $accepted_phaseID_arr, $homepage, $php_root_path, $GLOBALS["DB_PREFIX"], &$err_message);
//Get the paper information
if (($paperInfo = get_paper_info($_GET["paperid"], &$err_message)) === false) {
    do_html_header("View Abstract Failed", &$err_message);
    $err_message .= " Cannot retrieve information from database. <br>\n";
    $err_message .= "<br><br> Try <a href='view_abstract.php?paperid=" . $_GET["paperid"] . "'>again</a>?";
    do_html_footer(&$err_message);
    exit;
}
//Get the lastest file of the paper
if (($FileIDData = get_latestFile($_GET["paperid"], &$err_message)) === false) {
    do_html_header("View Abstract Failed", &$err_message);
    $err_message .= " Could not execute \"get_latestFile\" in \"view_abstract.php\". <br>\n";
    $err_message .= "<br><br> Try <a href='view_abstract.php?paperid=" . $_GET["paperid"] . "'>again</a>?";
    do_html_footer(&$err_message);
    exit;
}
if ($_POST["showing"]) {
    $_GET["showing"] = $_POST["showing"];
}
if ($_POST["sort"]) {
    $_GET["sort"] = $_POST["sort"];
}
if (!$_POST["referer"]) {
    //		echo $_SERVER["HTTP_REFERER"] ;
    $_POST["referer"] = $_SERVER["HTTP_REFERER"];
?>
<br><br>
<form name="form1" method="post" action="process_assign_paper.php">
  <table width="100%" border="0" cellspacing="2" cellpadding="1">
    <tr> 
      <td colspan="2" valign="top">Below is the paper you 
        are going to assign. Press Confirm to proceed.</td>
    </tr>
    <tr>
      <td colspan="2" valign="top">&nbsp;</td>
    </tr>
    <?php 
//Get the paper information
$paperInfo = get_paper_info($paperID);
//Get the lastest file of the paper
$FileIDData = get_latestFile($paperID, &$err_message);
?>
    <input type="hidden" value="<?php 
echo $paperID;
?>
" name="paperID">
	<!--Send an hidden value to distinguish between edit reviwers and assign reviewers-->
	<?php 
if (!empty($_POST["edit"])) {
    ?>
		<input type="hidden" value="true" name="edit">
	<?php 
}
?>
    <tr> 
      <td width="5%" valign="top"><div align="center"><?php 
function archive_next_paper($percent, &$bar)
{
    global $archive_papers;
    global $tarFile;
    global $totalPaperSize;
    global $extractSize;
    global $paperNotZipped;
    $paperNotZippedArr = explode(",", $paperNotZipped);
    $paperInfo = $archive_papers[$bar->getValue()];
    if (!$paperInfo) {
        return;
    }
    // Skip empty entries (applies to 100% too)
    $fileInfo = get_latestFile($paperInfo->PaperID, &$err_message);
    $paperSize = $fileInfo->FileSize;
    $totalPaperSize += $paperSize;
    //Last element of $paperNotZippedArr is a comma and is not looped.
    for ($i = 0; $i < count($paperNotZippedArr) - 1; $i++) {
        if ($paperNotZippedArr[$i] == $paperInfo->PaperID) {
            //echo $paperInfo -> PaperID;
            $fileEnding = strstr($fileInfo->FileName, '.');
            $data = $fileInfo->File;
            $name = $paperInfo->PaperID . $fileEnding;
            $tarFile->AddString("papers/" . $name, $data);
        }
    }
}
{ 
	$homepage->showmenu = 0 ;	
	do_html_header("Show All Reviews Failed" , &$err_message );	
	$err_message .= " The requested infomation is not available at this phase. <br>\n";
	$err_message .= "<br><br> Try <a href='show_all_reviews.php?paperid=".$_GET["paperid"]."'>again</a>?" ;
	do_html_footer( &$err_message );		
	exit ;
}		
*/
do_html_header("Show All Reviews", &$err_message);
//Establish connection with database
$db = adodb_connect(&$err_message);
//Get the paper information
$paperInfo = get_paper_info($_GET["paperid"]);
//Get the lastest file of the paper
$FileIDData = get_latestFile($_GET["paperid"], &$err_message);
//Retrieve the information from Review Table
$reviewSQL = "SELECT * FROM " . $GLOBALS["DB_PREFIX"] . "Review";
$reviewSQL .= " WHERE PaperID='" . $_GET["paperid"] . "'";
$reviewSQL .= " AND Comments != ''";
// LOOK OUT FOR NOT NULL
$reviewResult = $db->Execute($reviewSQL);
$numReviews = $reviewResult->RecordCount();
?>
<table width="100%" border="0" cellspacing="0" cellpadding="1">
  <tr> 
    <td><h4><?php 
echo stripslashes($paperInfo->Title);
?>
</h4></td>
  </tr>
	</select>		
<input type="submit" value="Go"></form></td><hr>
    </tr>
	<tr><td colspan="3"><hr></td></tr>
    <?php 
$loop = MAX_TAGS;
$quotient = ceil($totalPapers / MAX_TAGS);
$remainder = $totalPapers % MAX_TAGS;
if ($remainder > 0 && $showing / MAX_TAGS + 1 == $quotient) {
    $loop = $remainder;
}
for ($i = 0; $i < $loop; $i++) {
    //Get the information
    $paperInfo = $reviewResult->FetchNextObj();
    //Get the lastest file of the paper
    if (($FileIDData = get_latestFile($paperInfo->PaperID, &$err_message)) === false) {
        $err_message .= " Could not execute \"get_latestFile\" in \"view_assigned_papers.php\". <br>\n";
    }
    //Check whether the paper is already reviewed
    if (($reviewExist = check_review_exist($paperInfo->PaperID)) === NULL) {
        $err_message .= " Could not execute \"check_review_exist\" in \"view_assigned_papers.php\". <br>\n";
    }
    ?>
    <tr>
      <td valign="top"> <strong>#<?php 
    echo $paperInfo->PaperID . " ";
    ?>
</strong> </td>
      <td valign="top">
        <p><a href='view_file.php?fileid=<?php 
    echo $FileIDData->FileID;
Beispiel #6
0
function redisplay(&$paperid_array, &$process, &$dbprefix, $err_message = "")
{
    //Establish connection with database
    $db = adodb_connect(&$err_message);
    //global $_SESSION ;
    $i = 0;
    $array = array();
    reset($paperid_array);
    foreach ($paperid_array as $some => $paperID) {
        //Get the paper information
        if (($paperInfo = get_paper_info($paperID, &$err_message)) === false) {
            do_html_header("Update Paper Bids Failed", &$err_message);
            $err_message .= " Cannot retrieve information from database. <br>\n";
            $err_message .= "<br><br> Try <a href='" . $_SERVER["PHP_SELF"] . "?" . $_SERVER["QUERY_STRING"] . "'>again</a>?";
            do_html_footer(&$err_message);
            exit;
        }
        $array[$i]["paperid"] = $paperInfo->PaperID;
        $array[$i]["papertitle"] = stripslashes($paperInfo->Title);
        //Get the lastest file of the paper
        if (($FileIDData = get_latestFile($paperID, &$err_message)) === false) {
            do_html_header("Update Paper Bids Failed", &$err_message);
            $err_message .= " Could not execute \"get_latestFile\" in \"update_biddings.php\". <br>\n";
            $err_message .= "<br><br> Try <a href='" . $_SERVER["PHP_SELF"] . "?" . $_SERVER["QUERY_STRING"] . "'>again</a>?";
            do_html_footer(&$err_message);
            exit;
        }
        $array[$i]["fileid"] = $FileIDData->FileID;
        if ($catcomsep = getSelectedCategoryCommaSeparated($paperInfo->PaperID, &$err_message) || numCategories(&$err_message) == 0) {
            $array[$i]["cat"] = $catcomsep;
        } else {
            do_html_header("Update Paper Bids Failed", &$err_message);
            $err_message .= " Could not execute \"getSelectedCategoryCommaSeparated\" in \"update_biddings.php\". <br>\n";
            $err_message .= "<br><br> Try <a href='" . $_SERVER["PHP_SELF"] . "?" . $_SERVER["QUERY_STRING"] . "'>again</a>?";
            do_html_footer(&$err_message);
            exit;
        }
        if ($authors = retrieve_authors($paperInfo->PaperID, &$err_message)) {
            $array[$i]["author"] = $authors;
        } else {
            do_html_header("Update Paper Bids Failed", &$err_message);
            $err_message .= " Could not execute \"retrieve_authors\" in \"update_biddings.php\". <br>\n";
            $err_message .= "<br><br> Try <a href='" . $_SERVER["PHP_SELF"] . "?" . $_SERVER["QUERY_STRING"] . "'>again</a>?";
            do_html_footer(&$err_message);
            exit;
        }
        if ($process === "update") {
            $preferenceSQL = " SELECT PreferenceID FROM " . $GLOBALS["DB_PREFIX"] . "Selection ";
            $preferenceSQL .= " WHERE PaperID = " . $paperInfo->PaperID;
            $preferenceSQL .= " AND Membername = '" . $_SESSION["valid_user"] . "'";
            $preferenceResult = $db->Execute($preferenceSQL);
            if (!$preferenceResult) {
                do_html_header("Update Paper Bids Failed", &$err_message);
                $err_message .= " Could not query \"Selection\" table in database by \"redisplay()\" of \"update_biddings.php\". <br>\n";
                $err_message .= "<br><br> Try <a href='" . $_SERVER["PHP_SELF"] . "?" . $_SERVER["QUERY_STRING"] . "'>again</a>?";
                do_html_footer(&$err_message);
                exit;
            }
            $userPreference = $preferenceResult->FetchNextObj();
            $array[$i]["bidid"] = $userPreference->PreferenceID;
        }
        if ($bidtable = Generate_Preference_Radio_Input_Table($paperInfo->PaperID, $array[$i]["bidid"], &$err_message)) {
            $array[$i]["bid"] = $bidtable;
        } else {
            do_html_header("Update Paper Bids Failed", &$err_message);
            $err_message .= " Could not execute \"retrieve_authors\" in \"update_biddings.php\". <br>\n";
            $err_message .= "<br><br> Try <a href='" . $_SERVER["PHP_SELF"] . "?" . $_SERVER["QUERY_STRING"] . "'>again</a>?";
            do_html_footer(&$err_message);
            exit;
        }
        $i++;
    }
    //End of for loop
    return $array;
}
Beispiel #7
0
$privilege_root_path = "/admin";
require_once "includes/include_all_fns.inc";
session_start();
// extract ( $_SESSION , EXTR_REFS ) ;
$err_message = " Unable to process your request due to the following problems: <br>\n";
do_html_header("Assign Paper#" . $id);
//Establish database connection
$db = adodb_connect();
if (!$db) {
    echo "Could not connect to database server - please try later.";
    exit;
}
//Get the paper information
$paperInfo = get_paper_info($id);
//Get the lastest file of the paper
$FileIDData = get_latestFile($id, &$err_message);
?>
<form name="form1" method="post" action="process_assign_paper.php">
  <table width="100%" border="0" cellspacing="0" cellpadding="1">
    <tr> 
      <td><h4><?php 
echo stripslashes($paperInfo->Title);
?>
</h4></td>
    </tr>
    <tr> 
      <td>&nbsp;</td>
    </tr>
    <tr> 
      <td><strong>Authors:</strong><?php 
echo retrieve_authors($paperInfo->PaperID);
		</span>
		<span class="Info">
		<?php 
        echo "&nbsp;&nbsp;Chair: ";
        ?>
		<?php 
        echo $session->Session->FirstName . " " . $session->Session->LastName;
        ?>
		</span>
		</div>
	<?php 
        foreach ($session->Slots as $slot) {
            $paper = get_paper_info($slot->PaperID);
            $firstPage = $pageNumberOf[$slot->PaperID];
            $authors = retrieve_authors($paper->PaperID);
            $fileInfo = get_latestFile($paper->PaperID, &$err_message);
            $fileEnding = strstr($fileInfo->FileName, '.');
            ?>
			<div class="Indent"><nbsp;></div>  
			<div class="LeftColumn">
				<span class="Slot.PaperName">
				<a href="papers/<?php 
            echo $paper->PaperID . $fileEnding;
            ?>
">
				<?php 
            echo $paper->Title;
            ?>
				</a>
				</span>
				<br />
Beispiel #9
0
    foreach ($authors as $author => $papers) {
        ?>

<div class="Authors">
<span class="Author"><?php 
        echo $author;
        ?>
</span>
<span class="Paper">
<?php 
        $i = 0;
        //paper counter
        asort($papers, SORT_NUMERIC);
        //papers in ascending page number order
        foreach ($papers as $paper => $page) {
            $fileInfo = get_latestFile($paper, &$err_message);
            $fileEnding = strstr($fileInfo->FileName, '.');
            if ($i) {
                echo ", ";
            }
            $i++;
            //punctuation
            ?>
	<a href="papers/<?php 
            echo $paper . $fileEnding;
            ?>
">
	<?php 
            echo $page . "</a>";
        }
        ?>
Beispiel #10
0
		$err_message .= " Cannot retrieve information from database. <br>\n" ;
		$err = $err_message . "<br><br> Try <a href='view_abstract.php?id=$id'>again</a>?" ;
		do_html_footer(&$err);
		exit;
	}		
*/
//Get the paper information
if (($paperInfo = get_paper_info($id, &$err_message)) === false) {
    do_html_header("View Abstract Failed", &$err_message);
    $err_message .= " Cannot retrieve information from database. <br>\n";
    $err = $err_message . "<br><br> Try <a href='view_abstract.php?id={$id}'>again</a>?";
    do_html_footer(&$err);
    exit;
}
//Get the lastest file of the paper
if (($FileIDData = get_latestFile($id, &$err_message)) === false) {
    do_html_header("View Abstract Failed", &$err_message);
    $err_message .= " Could not execute \"get_latestFile\" in \"view_abstract.php\". <br>\n";
    $err = $err_message . "<br><br> Try <a href='view_abstract.php?id={$id}'>again</a>?";
    do_html_footer(&$err);
    exit;
}
do_html_header("View Abstract", &$err_message);
?>
<br>
<table width="100%" border="0" cellspacing="0" cellpadding="1">
    <tr> 
    <td><h4> #<?php 
echo $paperInfo->PaperID;
?>
 <nbsp> <?php