function validateData() { require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, 'admin'); $valid = true; if (!is_numeric($this->_sessionTimeout)) { $valid = false; $this->_sessionTimeoutError = $loc->getText("Session timeout must be numeric."); } elseif ($this->_sessionTimeout <= 0) { $valid = false; $this->_sessionTimeoutError = $loc->getText("Session timeout must be greater than 0."); } if (!is_numeric($this->_itemsPerPage)) { $valid = false; $this->_itemsPerPageError = $loc->getText("Items per page must be numeric."); } elseif ($this->_itemsPerPage <= 0) { $valid = false; $this->_itemsPerPageError = $loc->getText("Items per page must be greater than 0."); } if (!is_numeric($this->_purgeHistoryAfterMonths)) { $valid = false; $this->_purgeHistoryAfterMonthsError = $loc->getText("Months must be numeric."); } if (!is_numeric($this->_inactiveMemberAfterDays)) { $valid = false; $this->_inactiveMemberAfterDaysError = $loc->getText("Days must be numeric."); } return $valid; }
function T($msg, $vars = NULL) { # Kludge to adapt 1.0-pre code to 0.6 static $loc = NULL; if ($loc == NULL) { $loc = new Localize(OBIB_LOCALE, 'classes'); } return $loc->getText($msg, $vars); }
/** * getter for messages * * @param int $room * @param int $user * @param int $time * @param int $game * @return array */ public static function getMessages($room, $toUser = 0, $time = 0, $game = 0) { $colorRepository = new ColorRepository(TRUE); $colors = $colorRepository->getAll(); $colorList = array(); foreach ($colors as $color) { $colorList[$color['id']] = $color; } $query = 'SELECT user.*, message.* FROM ' . DB_PREFIX . self::$table . ' AS message LEFT JOIN ' . DB_PREFIX . 'user AS user ON message.user = user.id WHERE room=' . intval($room) . ' AND tstamp > ' . intval($time) . ' AND to_user IN (' . intval($toUser) . ', 0)'; if ($game) { $query .= ' AND game=' . intval($game); } if ($toUser) { $query .= ' AND NOT not_to_user IN (' . $toUser . ')'; } $query .= ' ORDER BY message.id DESC LIMIT 100'; $messages = DB::fetchAll($query); $messages = array_reverse($messages); foreach ($messages as &$message) { if ($message['localize_key']) { $message['text'] = Localize::getMessage($message['localize_key'], unserialize($message['localize_params'])); } $message['color'] = $colorList[$message['color']]['code']; } return $messages; }
/** * @param $errno * @param $errstr * @param $errfile * @param $errline * @param $errcontext */ static function error_handler($errno, $errstr, $errfile, $errline, $errcontext) { $default_domain = Localize::textDomain(NULL); Localize::textDomain(self::$domain); $format = "[%s] %s %s(%s)\n"; $lang_sub_list = array(__gt("array"), __gt("string"), __gt("object")); $lang_list = array(__gt('Missing argument %d for %s, called in'), __gt('Use of undefined constant %s - assumed \'%s\''), __gt('%s to %s conversion'), __gt('Illegal string offset \'%s\''), __gt('Call to undefined method'), __gt('Non-static method %s should not be called statically'), __gt('Call to protected method %s from context \'%s\''), __gt('Cannot access private property'), __gt('Undefined variable: %s'), __gt('Undefined index: %s'), __gt('Illegal offset type in isset or empty'), __gt('%s expects parameter %s to be %s, %s given'), __gt('Call to private method %s from context \'%s\''), __gt('Call to a member function %s on a non-object'), __gt('Invalid argument supplied for %s')); $errorno_str = array(E_ERROR => 'ERROR', E_WARNING => 'WARNING', E_PARSE => 'PARSE', E_NOTICE => 'NOTICE', E_CORE_ERROR => 'CORE_ERROR', E_CORE_WARNING => 'CORE_WARNING', E_COMPILE_ERROR => 'COMPILE_ERROR', E_COMPILE_WARNING => 'COMPILE_WARNING', E_USER_ERROR => 'USER_ERROR', E_USER_WARNING => 'USER_WARNING', E_USER_NOTICE => 'USER_NOTICE', E_STRICT => 'STRICT', E_RECOVERABLE_ERROR => 'RECOVERABLE_ERROR', E_DEPRECATED => 'DEPRECATED', E_USER_DEPRECATED => 'USER_DEPRECATED'); $errorno_list = array(E_ERROR => __('Fatal run-time errors'), E_WARNING => __('Run-time warnings (non-fatal errors)'), E_PARSE => __('Compile-time parse errors'), E_NOTICE => __('Run-time notices'), E_CORE_ERROR => __('Fatal errors that occur during PHP\'s initial startup'), E_CORE_WARNING => __('Warnings (non-fatal errors)'), E_COMPILE_ERROR => __('Fatal compile-time errors'), E_COMPILE_WARNING => __('Compile-time warnings (non-fatal errors)'), E_USER_ERROR => __('User-generated error message'), E_USER_WARNING => __('User-generated warning message'), E_USER_NOTICE => __('User-generated notice message'), E_STRICT => __('Enable to have PHP suggest changes to your code which will ensure the best interoperability and forward compatibility of your code'), E_RECOVERABLE_ERROR => __('Catchable fatal error'), E_DEPRECATED => __('Run-time notices'), E_USER_DEPRECATED => __('User-generated warning message')); $errno_lg = ""; if (isset($errorno_list[$errno])) { $errno_lg = $errorno_list[$errno]; } $errno = $errorno_str[$errno] . ":" . $errno_lg; foreach ($lang_list as $v) { $pv0 = self::get_pregstr($v[0]); if (preg_match("/" . $pv0 . "/", $errstr, $mt)) { $pv1 = self::get_pregstr_replace($v[1]); $errstr = preg_replace("/" . $pv0 . "/", $pv1, $errstr, 1); foreach ($lang_sub_list as $vv) { $pvv0 = self::get_pregstr($vv[0]); $pvv1 = self::get_pregstr_replace($vv[1]); $errstr = preg_replace("/([\\b])" . $pvv0 . "([\\b])/i", "\$1" . $pvv1 . "\$2", $errstr); } break; } } echo sprintf($format, $errno, $errstr, $errfile, $errline, $errcontext); Localize::textDomain($default_domain); }
function addLocalizeToLocs($locs, $page) { $localizes = Localize::where('`page` = "' . $page . '"', ['title', self::get_loc()]); foreach ($localizes as $loc) { $locs['localize_' . $loc->title] = $loc->{self::get_loc()}; } return $locs; }
/** * Smarty {localize} function plugin * */ function smarty_function_localize($params, &$smarty) { $attrs = array(); if ($params['attrs']) { $attrs = explode('###', $params['attrs']); } return Localize::getMessage($params['key'], $attrs); }
function validateData() { $loc = new Localize(OBIB_LOCALE, "classes"); $valid = true; if ($this->_isRequired and $this->_fieldData == "") { $valid = false; $this->_fieldDataError = $loc->getText("biblioFieldError1"); } if ($this->_tag == "") { $valid = false; $this->_tagError = $loc->getText("biblioFieldError1"); } else { if (!is_numeric($this->_tag)) { $valid = false; $this->_tagError = $loc->getText("biblioFieldError2"); } } if ($this->_subfieldCd == "") { $valid = false; $this->_subfieldCdError = $loc->getText("biblioFieldError1"); } // Check for image if ($this->getTag() == "902" && $this->getSubfieldCd() == "a") { $fieldData = $this->getFieldData(); $index = $this->getTag() . $this->getSubfieldCd(); if (!empty($fieldData["tmp_name"][$index])) { if ($info = getimagesize($fieldData["tmp_name"][$index])) { $filename = $fieldData["name"][$index]; $filename_parts = explode(".", $filename); unset($filename_parts[count($filename_parts) - 1]); $filename = implode("-", $filename_parts); $allow_types = array('image/jpeg', 'image/png', 'image/gif'); // If file type is allowed if (in_array($info["mime"], $allow_types)) { $ext = image_type_to_extension($info[2]); $tmp = md5($filename . session_id() . time()); $filename = $filename . "_" . substr($tmp, strlen($tmp) - 7, strlen($tmp)) . $ext; $filepath = "../pictures/{$filename}"; copy($fieldData["tmp_name"][$index], $filepath); make_thumbnail($filepath, array('width' => 200)); $this->setFieldData($filename); } else { $valid = false; $this->_fieldDataError = $loc->getText("biblioFieldErrorPictureType"); } } else { $valid = false; $this->_fieldDataError = $loc->getText("biblioFieldErrorPictureType"); } } } unset($loc); return $valid; }
/** * Set locale of output data * * @param string $locale Name of locale, the same format of setlocale php function * * @return Localize Current instance of that class, for chaining methods */ public static function setLocale($locale) { $locales = array($locale . '.utf-8', $locale . '.UTF-8', $locale); $os = strtolower(php_uname('s')); if (strpos($os, 'windows') !== false) { $locales = array(Formats::$windowsLocaleMap[$locale]); } if (!setlocale(LC_ALL, $locales)) { throw new LocaleException("Locale {$locale} não disponível no seu sistema."); } self::$currentLocale = $locale; return new static(); }
protected function setup() { $loggedUser = LoggedUser::whoIsLogged(); if (Utils::post('create_room') && $loggedUser['admin']) { $params = array('title' => Utils::post('title'), 'alias' => Utils::createAlias(Utils::post('title'), 'room'), 'description' => Utils::post('description')); $room = new Room($params); $room->save(); } $roomRepository = new RoomRepository(); $rooms = $roomRepository->getAll(); $gameRepository = new GameRepository(); $games = $gameRepository->getGamesByRooms(array_keys($rooms)); foreach ($games as $game) { $rooms[$game['room']]['game'] = TRUE; $rooms[$game['room']]['status'] = Localize::getMessage('room_status_' . $game['status']); } MySmarty::assign('loggedUser', $loggedUser); MySmarty::assign('rooms', $rooms); }
public static function init() { $cacheFileName = dirname(__FILE__) . '/../tmp/cache/localize'; if (file_exists($cacheFileName)) { $file = fopen($cacheFileName, 'r'); $data = fread($file, filesize($cacheFileName)); fclose($file); self::$localizationMap = unserialize($data); } else { if (self::$localizationMap === NULL) { self::$localizationMap = array(); foreach (self::$dirs as $dir) { self::readDir($dir); } $file = fopen($cacheFileName, 'w'); fwrite($file, serialize(self::$localizationMap)); fclose($file); } } }
protected function setup() { $loggedUser = LoggedUser::whoIsLogged(); MySmarty::assign('loggedUser', $loggedUser); MySmarty::assign('room', $this->room); if ($this->game) { MySmarty::assign('game', $this->game); MySmarty::assign('gameStartedStatus', Game::GAME_STATUS_STARTED); $playerRepository = new PlayerRepository(); $actualPlayer = $playerRepository->getOneByGameAndUser($this->game['id'], $loggedUser['id']); // phases when we want to make autoreload $refreshGameBox = FALSE; if (in_array($actualPlayer['phase'], array(Player::PHASE_NONE, Player::PHASE_WAITING))) { if ($this->game['status'] == Game::GAME_STATUS_INITIALIZED && $actualPlayer['possible_choices'] != '') { $refreshGameBox = FALSE; } else { $refreshGameBox = TRUE; } } MySmarty::assign('refreshGameBox', $refreshGameBox); // zobrazime len hracovi ktory je na tahu resp. v medzitahu $playerOnMove = $this->game->getPlayerOnMove(); if ($playerOnMove['id'] == $actualPlayer['id'] || $this->game['status'] == Game::GAME_STATUS_INITIALIZED) { MySmarty::assign('response', $actualPlayer['command_response']); } if ($this->game['status'] == Game::GAME_STATUS_CREATED) { if (!GameUtils::checkUserInGame($loggedUser, $this->game)) { MySmarty::assign('joinGameAvailable', TRUE); } elseif ($loggedUser['id'] == $this->game['creator']) { MySmarty::assign('startGameAvailable', Localize::getMessage('start_game')); } } elseif ($this->game['status'] == Game::GAME_STATUS_ENDED) { MySmarty::assign('createGameAvailable', Localize::getMessage('create_game')); MySmarty::assign('refreshGameBox', TRUE); } } else { MySmarty::assign('createGameAvailable', Localize::getMessage('create_game')); MySmarty::assign('refreshGameBox', TRUE); } }
/** * Sobrecarga do método input incluindo funcionalidades * extras, tais como: * * 1 - Localização automática dos tipos date/datetime e numérico/float * 2 - Formatação baseada no TwitterBootstrap * */ public function input($fieldName, $options = array()) { $this->setEntity($fieldName); $modelKey = $this->model(); $fieldKey = $this->field(); $fieldDef = $this->_introspectModel($modelKey, 'fields', $fieldKey); $value = null; if (isset($options['value'])) { $value = $options['value']; } else { if (isset($this->request->data[$modelKey][$fieldKey])) { $value = $this->request->data[$modelKey][$fieldKey]; } } if ((!isset($options['localize']) || $options['localize'] === true) && !empty($value)) { switch ($fieldDef['type']) { case 'date': $value = Localize::date($value); break; case 'datetime': case 'timestamp': $value = Localize::datetime($value); break; case 'float': $value = Localize::number($value); break; } $options['value'] = $value; } if ((!isset($options['keepSeconds']) || $options['keepSeconds'] === true) && $fieldDef['type'] === 'time') { $options['value'] = empty($value) || !preg_match('/[0-9]{2}\\:[0-9]{2}(\\:[0-9]{2})?/') ? '00:00' : substr($value, 0, 5); } if (!isset($options['useBootstrap']) || $options['useBootstrap'] === true) { /** * @todo Helper não deve estender o BootstrapForm, mas * sim usa-lo quando definido. */ } return parent::input($fieldName, $options); }
function validateData() { $loc = new Localize(OBIB_LOCALE, "classes"); $valid = true; if ($this->_isRequired and $this->_fieldData == "") { $valid = false; $this->_fieldDataError = $loc->getText("biblioFieldError1"); } if ($this->_tag == "") { $valid = false; $this->_tagError = $loc->getText("biblioFieldError1"); } else { if (!is_numeric($this->_tag)) { $valid = false; $this->_tagError = $loc->getText("biblioFieldError2"); } } if ($this->_subfieldCd == "") { $valid = false; $this->_subfieldCdError = $loc->getText("biblioFieldError1"); } unset($loc); return $valid; }
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../shared/common.php"; $tab = "home"; $nav = "home"; require_once "../shared/header.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, $tab); ?> <h1><?php echo $loc->getText("indexHeading"); ?> </h1> <?php # echo $loc->getText("searchResults",array("items"=>0))."<br>"; ?> <?php echo $loc->getText("indexIntro"); ?> <br><br> <table class="primary"> <tr> <th><?php echo $loc->getText("indexTab"); ?>
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../shared/common.php"; $tab = "admin"; $nav = "themes"; require_once "../shared/logincheck.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, $tab); #**************************************************************************** #* Checking for query string. Go back to theme list if none found. #**************************************************************************** if (!isset($_GET["themeid"])) { header("Location: ../admin/theme_list.php"); exit; } $themeid = $_GET["themeid"]; $name = $_GET["name"]; #************************************************************************** #* Show confirm page #************************************************************************** require_once "../shared/header.php"; ?> <center> <form name="delstaffform" method="POST" action="../admin/theme_del.php?themeid=<?php echo HURL($themeid); ?> &name=<?php echo HURL($name);
<script language="JavaScript1.1" > /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ // JavaScript Document //------------------------------------------------------------------------------ // lookup Javascript lkup = { <?php require_once REL(__FILE__, "../classes/Localize.php"); $jsLoc = new Localize(OBIB_LOCALE, $tab); echo "z3950Search\t\t\t\t:'" . $jsLoc->getText("lookup_z3950Search") . "',\n"; echo "isbn\t\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_isbn") . "',\n"; echo "issn\t\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_issn") . "',\n"; echo "lccn\t\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_lccn") . "',\n"; echo "title\t\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_title") . "',\n"; echo "author\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_author") . "',\n"; echo "keyword\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_keyword") . "',\n"; echo "publisher\t\t\t\t\t:'" . $jsLoc->getText("lookup_publisher") . "',\n"; echo "pubLoc\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_pubLoc") . "',\n"; echo "pubDate\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_pubDate") . "',\n"; echo "andOpt\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_andOpt") . "',\n"; echo "search\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_search") . "',\n"; echo "abandon\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_abandon") . "',\n"; echo "repository\t\t\t\t:'" . $jsLoc->getText("lookup_repository") . "',\n"; echo "yaz_setup_failed\t:'" . $jsLoc->getText("lookup_yazSetupFailed") . "',\n"; echo "badQuery\t\t\t\t\t:'" . $jsLoc->getText("lookup_badQuery") . "',\n"; echo "patience\t\t\t\t\t:'" . $jsLoc->getText("lookup_patience") . "',\n"; echo "resetInstr\t\t\t\t:'" . $jsLoc->getText("lookup_resetInstr") . "',\n"; echo "goBack\t\t\t\t\t\t:'" . $jsLoc->getText("lookup_goBack") . "',\n";
function _print($type, $namel, $options, $list, $prefix) { global $loc; assert('$loc'); assert('!empty($namel)'); // $loc_share = new Localize(OBIB_LOCALE, "shared"); // //jalg multi 5-7-2015 $loc_share = new Localize(OBIB_LOCALE, "shared"); if ($type == 'session_id') { return; } if (isset($options['hidden'])) { //jalg multi 5-7-2015 return; } if ($type == 'group') { echo '<tr><td class="' . $prefix . 'group" colspan="2">'; Params::printForm($list, $prefix, $namel); echo '</td></tr>'; return; } if ($type == 'order_by') { $title = 'Sort By'; } elseif (isset($options['title']) && $options['title']) { $title = $options['title']; } else { $title = $namel[count($namel) - 1]; } $name = $prefix . array_shift($namel); foreach ($namel as $n) { $name .= '[' . $n . ']'; } if (isset($options['default'])) { $default = $options['default']; } else { $default = ''; } echo '<tr class="' . $prefix . 'param">'; echo '<td><label for="' . H($name) . '">'; echo $loc->getText($title); echo '</label></td><td>'; switch ($type) { case 'string': echo inputField('text', $name, $default); break; case 'date': echo inputField('date', $name, $default); break; case 'select': $l = array(); foreach ($list as $v) { list($n, $o) = $v; if (isset($o['title']) && $o['title']) { $l[$n] = $loc->getText($o['title']); } elseif (strcmp($name, "rpt_material_type") == 0 || strcmp($name, "rpt_collection") == 0) { $l[''] = $loc_share->getText("any"); foreach ($o as $i) { $l[$o['code']] = $o['description']; } } else { $l[$n] = $n; } } echo inputField('select', $name, $default, NULL, $l); break; case 'order_by': $l = array(); foreach ($list as $v) { list($n, $o) = $v; if (isset($o['title']) and $o['title']) { $l[$n] = $loc->getText($o['title']); } else { $l[$n] = $n; } $l[$n . '!r'] = $l[$n] . ' ' . $loc->getText('reportsReverse'); // $l[$n.'!r'] = $l[$n].' ('.$loc->getText("Reverse").')';// revisar de ALX } echo inputField('select', $name, $default, NULL, $l); break; default: assert(NULL); } echo '</td></tr>'; }
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../shared/common.php"; session_cache_limiter(null); $tab = "admin"; $nav = "lookupOpts"; $focus_form_name = "editForm"; $focus_form_field = "protocol"; require_once REL(__FILE__, "../functions/inputFuncs.php"); require_once REL(__FILE__, "../shared/logincheck.php"); require_once REL(__FILE__, "../shared/header.php"); require_once REL(__FILE__, "../classes/Localize.php"); $loc = new Localize(OBIB_LOCALE, $tab); ?> <form id="editForm" name="editForm" method="POST" > <h5 id="updateMsg"></h5> <table class="primary"> <tbody> <tr> <th colspan="2" nowrap="yes" align="left"> <?php echo $loc->getText("lookup_optsSettings"); ?> </th> </tr> <tr> <td nowrap="true" class="primary">
$temp_return_page = ""; if (isset($_GET["RET"])) { if (in_array($_GET["RET"], $pages, true)) { $_SESSION["returnPage"] = $_GET["RET"]; } else { $_SESSION["returnPage"] = '../home/index.php'; } } $tab = "home"; $nav = ""; $focus_form_name = "loginform"; $focus_form_field = "username"; require_once "../shared/get_form_vars.php"; require_once "../shared/header.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, "shared"); ?> <br> <center> <form name="loginform" method="POST" action="../shared/login.php"> <table class="primary"> <tr> <th><?php echo $loc->getText("loginFormTbleHdr"); ?> :</th> </tr> <tr> <td valign="top" class="primary" align="left"> <table class="primary">
$mbrid = $_GET["mbrid"]; if ($mbrid == "") { $tab = "cataloging"; $nav = "holds"; $returnNav = "../catalog/biblio_hold_list.php?bibid=" . U($bibid); } else { $tab = "circulation"; $nav = "view"; $returnNav = "../circ/mbr_view.php?mbrid=" . U($mbrid); } $restrictInDemo = TRUE; require_once "../shared/logincheck.php"; require_once "../classes/BiblioHoldQuery.php"; require_once "../functions/errorFuncs.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, "shared"); #************************************************************************** #* Delete hold #************************************************************************** // we need to also insert into status history table $holdQ = new BiblioHoldQuery(); $holdQ->connect(); if ($holdQ->errorOccurred()) { $holdQ->close(); displayErrorPage($holdQ); } $rc = $holdQ->delete($bibid, $copyid, $holdid); if (!$rc) { $holdQ->close(); displayErrorPage($copyQ); }
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../shared/common.php"; $tab = "cataloging"; $nav = ""; require_once "../classes/Biblio.php"; require_once "../classes/BiblioField.php"; require_once "../classes/BiblioQuery.php"; require_once "../functions/fileIOFuncs.php"; require_once "../shared/logincheck.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, $tab); if (count($_FILES) == 0) { header("Location: upload_usmarc_form.php"); exit; } include "../shared/header.php"; require_once "import_usmarc_excludes.php"; $recordterminator = ""; $fieldterminator = ""; $delimiter = ""; $usmarc_str = fileGetContents($_FILES["usmarc_data"]["tmp_name"]); $records = explode($recordterminator, $usmarc_str); // We separated with a terminator, so the last element will always be empty. array_pop($records); $biblios = array(); foreach ($records as $record) { $biblio = new Biblio();
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../classes/Localize.php"; $headerLoc = new Localize(OBIB_LOCALE, "shared"); // code html tag with language attribute if specified. echo "<html"; if (OBIB_HTML_LANG_ATTR != "") { echo " lang=\"" . H(OBIB_HTML_LANG_ATTR) . "\""; } echo ">\n"; // code character set if specified if (OBIB_CHARSET != "") { ?> <META http-equiv="content-type" content="text/html; charset=<?php echo H(OBIB_CHARSET); ?> "> <?php } ?> </script> <?php ## --------------------------------------------------------------------- ## --- added for Fred LaPlante's Lookup Function ----------------------- if (file_exists('customHead.php')) { include 'customHead.php'; } ## ---------------------------------------------------------------------
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../shared/common.php"; $tab = "admin"; $nav = "classifications"; $restrictInDemo = true; require_once "../shared/logincheck.php"; require_once "../classes/Dm.php"; require_once "../classes/DmQuery.php"; require_once "../functions/errorFuncs.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, $tab); #**************************************************************************** #* Checking for post vars. Go back to form if none found. #**************************************************************************** if (count($_POST) == 0) { header("Location: ../admin/mbr_classify_new_form.php"); exit; } #**************************************************************************** #* Validate data #**************************************************************************** $dm = new Dm(); $dm->setDescription($_POST["description"]); $_POST["description"] = $dm->getDescription(); $dm->setMaxFines($_POST["max_fines"]); $_POST["max_fines"] = $dm->getMaxFines(); if (!$dm->validateData()) {
<?php require_once "../shared/common.php"; $tab = "home"; $nav = "license"; include "../shared/header.php"; $loc = new Localize(OBIB_LOCALE, $tab); ?> <h1><?php echo $loc->getText("licenseHeading"); ?> </h1> <br> <pre> <a href="#en">Versión oficial en ingles</a> <a href="#espa">Versión no oficial en español</a></br></br> </br><a name="en">Versión oficial en ingles</a></br> GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your
# Redirect to biblio_view if only one result if ($biblioQ->getRowCount() == 1) { $biblio = $biblioQ->fetchRow(); header('Location: ../shared/biblio_view.php?bibid=' . U($biblio->getBibid()) . '&tab=' . U($tab)); exit; } #************************************************************************** #* Show search results #************************************************************************** if ($tab == "opac") { require_once "../shared/header_opac.php"; } else { require_once "../shared/header.php"; } require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, "shared"); # Display no results message if no results returned from search. if ($biblioQ->getRowCount() == 0) { $biblioQ->close(); echo $loc->getText("biblioSearchNoResults"); require_once "../shared/footer.php"; exit; } ?> <!--************************************************************************** * Javascript to post back to this page ************************************************************************** --> <script language="JavaScript" type="text/javascript"> <!-- function changePage(page,sort)
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../shared/common.php"; $tab = "admin"; $nav = "checkout_privs"; require_once "../classes/CheckoutPrivsQuery.php"; require_once "../functions/errorFuncs.php"; require_once "../shared/logincheck.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, $tab); require_once "../shared/header.php"; $privsQ = new CheckoutPrivsQuery(); $privsQ->connect(); $privs = $privsQ->getAll(); $privsQ->close(); ?> <h1><?php echo $loc->getText("Checkout Privileges"); ?> </h1> <table class="primary"> <tr> <th valign="top"><?php echo $loc->getText("function"); ?> </th> <th valign="top"> <?php
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../classes/Localize.php"; $navLoc = new Localize(OBIB_LOCALE, "navbars"); if (isset($_SESSION["userid"])) { $sess_userid = $_SESSION["userid"]; } else { $sess_userid = ""; } if ($sess_userid == "") { ?> <input type="button" onClick="self.location='../shared/loginform.php?RET=../reports/index.php'" value="<?php echo $navLoc->getText("login"); ?> " class="navbutton"> <?php } else { ?> <input type="button" onClick="self.location='../shared/logout.php'" value="<?php echo $navLoc->getText("logout"); ?> " class="navbutton"> <?php } ?> <br /><br /> <?php Nav::node('reportlist', 'Report List', '../reports/index.php');
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../shared/common.php"; $tab = "admin"; $nav = "staff"; $restrictInDemo = true; require_once "../shared/logincheck.php"; require_once "../classes/Staff.php"; require_once "../classes/StaffQuery.php"; require_once "../functions/errorFuncs.php"; require_once "../classes/Localize.php"; $loc = new Localize(OBIB_LOCALE, $tab); #**************************************************************************** #* Checking for post vars. Go back to form if none found. #**************************************************************************** if (count($_POST) == 0) { header("Location: ../admin/staff_list.php"); exit; } #**************************************************************************** #* Validate data #**************************************************************************** $staff = new Staff(); $staff->setUserid($_POST["userid"]); $staff->setPwd($_POST["pwd"]); $_POST["pwd"] = $staff->getPwd(); $staff->setPwd2($_POST["pwd2"]); $_POST["pwd2"] = $staff->getPwd2();
<input id="choiceBtn1" type="button" value="<?php echo $lookLoc->getText("lookup_goBack"); ?> " class="button" /> <span id="choiceSpace"> Search Results go here </span> <input id="choiceBtn2" type="button" value="<?php echo $lookLoc->getText("lookup_goBack"); ?> " class="button" /> </div> <div id="selectionDiv"> <?php $focus_form_name = "newbiblioform"; $focus_form_field = "materialCd"; $loc = new Localize(OBIB_LOCALE, $tab); $headerWording = $loc->getText("biblioNewFormLabel"); ## we use original biblio edit screen, but will replace existing 'Cancel' button print '<form name="newbiblioform" method="POST" action="../catalog/biblio_new.php" >'; include "../catalog/biblio_fields.php"; ?> </div> <?php ## needed for all cases include "../shared/footer.php";
<?php /* This file is part of a copyrighted work; it is distributed with NO WARRANTY. * See the file COPYRIGHT.html for more details. */ require_once "../classes/Localize.php"; $navloc = new Localize(OBIB_LOCALE, "navbars"); ?> <input type="button" onClick="self.location='../shared/logout.php'" value="<?php echo $navloc->getText("Logout"); ?> " class="navbutton"><br /> <br /> <?php if ($nav == "searchform") { ?> » <?php echo $navloc->getText("memberSearch"); ?> <br> <?php } else { ?> <a href="../circ/index.php" class="alt1"><?php echo $navloc->getText("memberSearch"); ?> </a><br> <?php } ?>