function output_cover($item_record) { global $db, $mysql, $pm; $xo = 1; $yo = 0.5; $txo = 0; $tyo = -19; $bw = 2.25; $bh = 0.403; $lw = 2.781; $lh = 1; $dlw = 4.625; $dlh = 4.625; $lox = $xo; $loy = $yo; $box = $lox + $lh / 2 - $bh / 2; $boy = $loy + ($lw - $bw) / 2; $tw = 7.5; $barcode_type = "AB"; $barcode_code = $item_record->barcode; $barcode_height = "60"; $barcode_command = "save"; include $db->common_image_dir . "/barcode.php"; $color_lightgray = imagecolorallocate($image_barcode, 128, 128, 128); $pm->set_font("helvetica"); $pm->set_font("times"); $pm->SetX(0); $pm->SetY(0); //$pm->rect($xo + 0, $yo + 0, 10.5, 7.25); $pm->image_jpeg($barcode_filename, $box, $boy, $bw, $bh); unlink($barcode_filename); //$pm->rect($xo, $yo, $dlw, $dlh, FALSE, 2.3125); //$pm->rect($xo + 2, $yo + 2, 0.6875, 0.6875, FALSE, 0.34375); $pm->set_draw_color(200, 200, 200); $pm->rect($lox, $loy, $lw, $lh, FALSE, 0.1); $pm->text($box - 0.25, $boy + $bw / 2, 0.15, "Immanuel Mission Library", "center"); $pm->text($box + $bh + 0.02, $boy + $bw / 2, 0.15, "" . trim(preg_replace("/(.)/", "\\1 ", $barcode_code)) . "", "center"); $title_xo = $xo + 1.3; $title_yo = $yo; $pm->set_font("helvetica"); $spine_title = array(); $pm->text_wrap($xo, $loy + $lw + 0.5, 0.2, "IMPORTANT: To checkout remove map from sleave. Do not remove this page or plastic sleeve.", 7.5 - $loy - $lw - 0.75, "left"); $call_number_parts = explode(",", $item_record->call_number); $cnx = 0.25; foreach ($call_number_parts as $key => $call_number_line) { $pm->text($cnx, 7.5, 0.1875, "<b>" . $call_number_line . "</b>", "left"); $cnx += 0.2; } // end foreach if ($series_record = lookup_designation($db->table_library_series, $item_record->{$db->field_library_series_ID})) { $series_title = $series_record->title . ($item_record->series_number > 0 ? " - #" . $item_record->series_number : ""); $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.22, $series_title, $tw, "left") + 0.06; $spine_title[] = $series_title; } // end if $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.36, $item_record->title, $tw, "left") + 0.06; if ($item_record->parallel_title != "") { $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.22, $item_record->parallel_title, $tw, "left"); } // end if if ($item_record->summary != "") { $title_xo += 0.2; $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.2, $item_record->summary, $tw, "left"); } // end if }
{ if(document.getElementById('publisher_iframe').style.display=='inline') { document.getElementById('publisher_iframe').style.display = 'none'; document.getElementById('publisher_lookup_button').focus(); } else { document.getElementById('publisher_iframe').style.display = 'inline'; document.getElementById('publisher_iframe').contentWindow.document.getElementById('lookup_query_input').focus(); document.getElementById('publisher_iframe').contentWindow.document.getElementById('lookup_query_input').select(); }; // end if }; // end function </script> <?php if (!($publisher_record = lookup_designation($db->table_publisher, $_POST['publisher_ID']))) { $publisher_record = (object) NULL; $publisher_record->ID = 0; $publisher_record->title = ""; $publisher_record->location = ""; } // end if ?> <input id="publisher_ID" name="publisher_ID" type="hidden" value="<?php echo $publisher_record->ID; ?> "> <input id="publisher_title" class="edit_record_link" type="text" value="<?php echo htmlspecialchars($publisher_record->title . ($publisher_record->location != "" ? " - " . $publisher_record->location : "")); ?> " size="28" readonly autocomplete="off">
$pm->rect($lox, $loy, $lw, $lh, FALSE, 0.1); $pm->text($box - 0.25, $boy + $bw / 2, 0.15, "Immanuel Mission Library", "center"); $pm->text($box + $bh + 0.02, $boy + $bw / 2, 0.15, "" . trim(preg_replace("/(.)/", "\\1 ", $barcode_code)) . "", "center"); $title_xo = $xo + 1.3; $title_yo = $yo; $pm->set_font("helvetica"); $spine_title = array(); $pm->text_wrap($xo, $loy + $lw + 0.5, 0.2, "IMPORTANT: To checkout remove map from sleave. Do not remove this page or plastic sleeve.", 7.5 - $loy - $lw - 0.75, "left"); $call_number_parts = explode(",", $item_record->call_number); $cnx = 0.25; foreach ($call_number_parts as $key => $call_number_line) { $pm->text($cnx, 7.5, 0.1875, "<b>" . $call_number_line . "</b>", "left"); $cnx += 0.2; } // end foreach if ($series_record = lookup_designation($db->table_library_series, $item_record->{$db->field_library_series_ID})) { $series_title = $series_record->title . ($item_record->series_number > 0 ? " - #" . $item_record->series_number : ""); $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.22, $series_title, $tw, "left") + 0.06; $spine_title[] = $series_title; } // end if $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.36, $item_record->title, $tw, "left") + 0.06; if ($item_record->parallel_title != "") { $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.22, $item_record->parallel_title, $tw, "left"); } // end if if ($item_record->summary != "") { $title_xo += 0.2; $title_xo += $pm->text_wrap($title_xo, $title_yo, 0.2, $item_record->summary, $tw, "left"); } // end if
$sql = "\n\t\tUPDATE\n\t\t\t`" . $db->table_account . "`\n\t\tSET\n\t\t\t`library_award_points`='" . mysql_escape_string($updated_library_award_points) . "'\n\t\tWHERE\n\t\t\t`ID`='" . $account_record->ID . "'\n\t"; mysql_query($sql, $mysql->link); $already_returned = FALSE; } else { $already_returned = TRUE; } // end if switch ($checkout_type) { case "checkout": header("location:" . $db->url_root . "/item_checkout.php/auto/" . $item_record->barcode); exit; break; case "return": $db->home_reset = 5; $location_record = lookup_designation($db->table_location, $item_record->{$db->field_location_ID}); $category_record = lookup_designation($db->table_category, $item_record->{$db->field_category_ID}); $call_number = implode(" ", explode(",", $item_record->call_number)); if ($location_record->ID == $db->ID_location_main) { $db->kiosk_sound = $db->common_sound_url . "/double.mp3"; } else { $db->kiosk_sound = $db->common_sound_url . "/heartput.mp3"; } // end if include_once dirname(__FILE__) . "/kiosk_top.php"; if ($item_record->{$db->field_library_series_ID} > 0) { ?> <div class="action_bar"><span class="action_heading"><?php echo $series_record->title; echo $record->series_number > 0 ? " - #" . $item_record->series_number : ""; ?> </span></div><?php
?> </select> </div> <?php include_once dirname(__FILE__) . "/bottom.php"; exit; } // end if if ($barcode != "") { $sql = "\n\t\tUPDATE\n\t\t\t`" . $db->table_library_item . "`\n\t\tSET\n\t\t\t`" . $db->field_location_ID . "`='" . mysql_escape_string($location_ID) . "',\n\t\t\t`" . $db->field_category_ID . "`='" . mysql_escape_string($category_ID) . "'\n\t\tWHERE\n\t\t\t`barcode`='" . mysql_escape_string($barcode) . "'\n\t"; mysql_query($sql, $mysql->link); header("location:" . $db->url_root . "/set_shelving_category.php/" . $location_ID . "/" . $category_ID); exit; } // end if $category_record = lookup_designation($db->table_category, $category_ID); include_once dirname(__FILE__) . "/top.php"; $sql = "\n\tSELECT\n\t\t*\n\tFROM\n\t\t`" . $db->table_account . "`\n\tWHERE\n\t\t`ID`='" . $account_ID . "'\n\t\tAND `enabled`='Y'\n"; $result = mysql_query($sql, $mysql->link); $record = mysql_fetch_object($result); ?> <script language="javascript"> function submit_barcode() { if(document.getElementById('barcode_input').value.length == <?php echo $db->barcode_length; ?> && document.getElementById('barcode_input').value.substring(0, 1) == "<?php echo $db->barcode_item_prefix; ?> ")