示例#1
0
 function get_maj_environnement($source_id)
 {
     global $outputtype, $import_type, $import_file;
     global $base_path, $charset;
     $envt = array();
     //Copie du fichier dans le répertoire temporaire
     $origine = str_replace(" ", "", microtime());
     $origine = str_replace("0.", "", $origine);
     if ($_FILES['import_file']['name']) {
         if (!@copy($_FILES['import_file']['tmp_name'], "{$base_path}/temp/" . $origine . $_FILES['import_file']['name'])) {
             error_message_history($msg["ie_tranfert_error"], $msg["ie_transfert_error_detail"], 1);
             exit;
         } else {
             $file_in = $origine . $_FILES['import_file']['name'];
         }
     }
     $envt["file_in"] = $file_in;
     if (!$import_type) {
         $envt["outputtype"] = $outputtype;
     }
     $envt["import_type"] = $import_type;
     $envt["origine"] = $origine;
     return $envt;
 }
示例#2
0
         // regarde si le champ est déjà dans la liste des champs à trier et le remplace si besoin
         $new_s = preg_replace("/{$sortfield}, /", "", $s);
         $new_s = preg_replace("/{$sortfield}/", "", $new_s);
         // ajoute la clause order by correcte
         $new_s = preg_replace("/order\\s+by\\s+/i", "order by {$tri}", $new_s);
         // replace l'ancienne chaîne par la nouvelle
         $valeur = str_replace($s, $new_s, $valeur);
     } else {
         $valeur .= " order by {$tri}";
     }
 }
 print pmb_bidi("<strong>{$msg['procs_ligne']} {$cle} </strong>:&nbsp;{$valeur}<br /><br />");
 if (pmb_strtolower(pmb_substr($valeur, 0, 6)) == "select" || pmb_strtolower(pmb_substr($valeur, 0, 6)) == "create") {
 } else {
     echo "rqt=" . $valeur . "=<br />";
     error_message_history("Requête invalide", "Vous ne pouvez tester que des requêtes de sélection", 1);
     exit;
 }
 if (!explain_requete($valeur)) {
     die("<br /><br />" . $valeur . "<br /><br />" . $msg["proc_param_explain_failed"] . "<br /><br />" . $erreur_explain_rqt);
 }
 $res = @pmb_mysql_query($valeur, $dbh);
 $nbr_lignes = @pmb_mysql_num_rows($res);
 $nbr_champs = @pmb_mysql_num_fields($res);
 if ($nbr_lignes) {
     echo "<table >";
     for ($i = 0; $i < $nbr_champs; $i++) {
         // ajout de liens pour trier les pages
         $fieldname = pmb_mysql_field_name($res, $i);
         $sortasc = "<a href='{$urlbase}&sortfield=" . ($i + 1) . "&desc=0'>asc</a>";
         $sortdesc = "<a href='{$urlbase}&sortfield=" . ($i + 1) . "&desc=1'>desc</a>";
示例#3
0
// +-------------------------------------------------+
// © 2002-2004 PMB Services / www.sigb.net pmb@sigb.net et contributeurs (voir www.sigb.net)
// +-------------------------------------------------+
// $Id: expl_update.inc.php,v 1.28 2015-04-16 11:39:22 jpermanne Exp $
if (stristr($_SERVER['REQUEST_URI'], ".inc.php")) {
    die("no access");
}
require_once $class_path . "/notice.class.php";
// Pour l'indexation des concepts
require_once $class_path . "/index_concept.class.php";
$expl_id = "";
//Vérification des champs personalisés
$p_perso = new parametres_perso("expl");
$nberrors = $p_perso->check_submited_fields();
if ($nberrors) {
    error_message_history($msg["notice_champs_perso"], $p_perso->error_message, 1);
    exit;
}
switch ($sub) {
    case 'create':
        $requete = "SELECT count(1) FROM exemplaires WHERE expl_cb='{$f_ex_cb}' ";
        $res = pmb_mysql_query($requete, $dbh);
        $nbr_lignes = pmb_mysql_result($res, 0, 0);
        $nbr_lignes ? $valid_requete = FALSE : ($valid_requete = TRUE);
        $requete = "INSERT INTO exemplaires SET create_date=sysdate(), ";
        $limiter = "";
        $libelle = $msg[4007];
        break;
    case 'update':
        // ceci teste si l'exemplaire cible existe bien
        $requete = "SELECT expl_id FROM exemplaires WHERE expl_cb='{$org_cb}' ";
示例#4
0
$base_nobody = 1;
$base_nosession = 0;
require $base_path . "/includes/init.inc.php";
//Supression du fichier transmis
@unlink("{$base_path}/temp/{$file_in}");
//Fichier converti
$f = explode(".", $file_in);
if (count($f) > 1) {
    unset($f[count($f) - 1]);
}
$file_out = implode(".", $f) . "." . $suffix . "~";
//Téléchargement
if (!file_exists("{$base_path}/temp/{$file_out}")) {
    print $std_header;
    print "<body>";
    error_message_history($msg['admin_convert_erreur_destination'], $msg['admin_convert_fichier_existe'], 0);
    exit;
}
if ($deliver == 3) {
    if (!$mimetype) {
        header("Content-Type: application/download");
    } else {
        header("Content-Type: " . $mimetype);
    }
    header("Content-Length: " . filesize("{$base_path}/temp/{$file_out}"));
    header("Content-Disposition: attachment; filename=" . implode(".", $f) . ".{$suffix}");
    @readfile("{$base_path}/temp/{$file_out}");
    @unlink("{$base_path}/temp/{$file_out}");
} else {
    //@copy("$base_path/temp/$file_out","$base_path/admin/import/unimarc.fic");
    @copy("{$base_path}/temp/{$file_out}", "{$base_path}/admin/import/unimarc" . (defined("LOCATION") ? "_" . constant("LOCATION") : "") . ".fic");
示例#5
0
function print_results($sc, $table, $url, $url_to_search_form, $hidden_form = true, $search_target = "")
{
    global $dbh;
    global $begin_result_liste;
    global $nb_per_page_search;
    global $page;
    global $charset;
    global $search;
    global $msg;
    global $pmb_nb_max_tri;
    global $affich_tris_result_liste;
    global $pmb_allow_external_search;
    global $show_results_data;
    global $option_show_expl, $option_show_notice_fille;
    global $gestion_acces_active, $gestion_acces_user_notice;
    global $PMBuserid;
    global $explr_invisible, $pmb_droits_explr_localises;
    //droits d'acces lecture notice
    if ($gestion_acces_active == 1 && $gestion_acces_user_notice == 1) {
        $ac = new acces();
        $dom_1 = $ac->setDomain(1);
        $usr_prf = $dom_1->getUserProfile($PMBuserid);
        $requete = "delete from {$table} using {$table}, exemplaires, acces_res_1 ";
        $requete .= "where ";
        $requete .= "{$table}.expl_id=exemplaires.expl_id ";
        $requete .= "and expl_bulletin=0 ";
        $requete .= "and expl_notice = res_num ";
        $requete .= "and usr_prf_num=" . $usr_prf . " and (((res_rights ^ res_mask) & 4)=0) ";
        pmb_mysql_query($requete, $dbh);
        $requete = "delete from {$table} using {$table}, exemplaires, bulletins, acces_res_1 ";
        $requete .= "where ";
        $requete .= "{$table}.expl_id=exemplaires.expl_id ";
        $requete .= "and expl_notice=0 ";
        $requete .= "and expl_bulletin=bulletin_id ";
        $requete .= "and bulletin_notice=res_num ";
        $requete .= "and usr_prf_num=" . $usr_prf . " and (((res_rights ^ res_mask) & 4)=0) ";
        pmb_mysql_query($requete, $dbh);
    }
    //visibilité des exemplaires
    if ($pmb_droits_explr_localises && $explr_invisible) {
        $requete = "delete from {$table} using {$table}, exemplaires ";
        $requete .= "where ";
        $requete .= "{$table}.expl_id=exemplaires.expl_id ";
        $requete .= "and expl_location in ({$explr_invisible})";
        pmb_mysql_query($requete, $dbh);
    }
    $start_page = $nb_per_page_search * $page;
    $requete = "select count(1) from {$table}";
    $res = pmb_mysql_query($requete);
    if ($res) {
        $nb_results = pmb_mysql_result(pmb_mysql_query($requete), 0, 0);
    } else {
        $nb_results = 0;
    }
    $requete = "select {$table}.* from " . $table . ", exemplaires where exemplaires.expl_id={$table}.expl_id";
    if ($nb_results > $sc->nb_per_page) {
        $requete .= " limit " . $start_page . ", " . $nb_per_page_search;
    }
    //Y-a-t-il une erreur lors de la recherche ?
    if ($sc->error_message) {
        error_message_history("", $sc->error_message, 1);
        exit;
    }
    if ($hidden_form) {
        print $sc->make_hidden_search_form($url);
    }
    $resultat = pmb_mysql_query($requete, $dbh);
    $human_requete = $sc->make_human_query();
    print "<strong>" . $msg["search_search_exemplaire"] . "</strong> : " . $human_requete;
    if ($nb_results) {
        print " => " . $nb_results . " " . $msg["search_expl_nb_result"] . "<br />\n";
        print $begin_result_liste;
        if ($sc->rec_history) {
            //Affichage des liens paniers et impression
            $current = $_SESSION["CURRENT"];
            if ($current !== false) {
                print "&nbsp;<a href='#' onClick=\"openPopUp('./print_cart.php?current_print={$current}&action=print_prepare','print',600,700,-2,-2,'scrollbars=yes,menubar=0,resizable=yes'); return false;\"><img src='./images/basket_small_20x20.gif' border='0' align='center' alt=\"" . $msg["histo_add_to_cart"] . "\" title=\"" . $msg["histo_add_to_cart"] . "\"></a>&nbsp;";
                //				if ($nb_results<=$pmb_nb_max_tri) print $affich_tris_result_liste;
            }
        }
    } else {
        print "<br />" . $msg["1915"] . " ";
    }
    print "<input type='button' class='bouton' onClick=\"document.search_form.action='{$url_to_search_form}'; document.search_form.target='{$search_target}'; document.search_form.submit(); return false;\" value=\"" . $msg["search_back"] . "\"/>";
    // transformation de la recherche en multicritères: on reposte tout avec mode=6
    print "&nbsp;<input  type='button' class='bouton' onClick='document.search_transform.submit(); return false;' value=\"" . $msg["search_expl_to_notice_transformation"] . "\"/>";
    print "<form name='search_transform' action='./catalog.php?categ=search&mode=6&sub=launch'  method='post' style='display:none;'>";
    foreach ($_POST as $key => $val) {
        if ($val) {
            if (is_array($val)) {
                foreach ($val as $cle => $val_array) {
                    if (is_array($val_array)) {
                        foreach ($val_array as $valeur) {
                            print "<input type='hidden' name=\"" . $key . "[" . $cle . "][]\" value='" . htmlentities($valeur, ENT_QUOTES, $charset) . "'/>";
                        }
                    } else {
                        print "<input type='hidden' name='" . $key . "[]' value='" . htmlentities($val_array, ENT_QUOTES, $charset) . "'/>";
                    }
                }
            } else {
                print "<input type='hidden' name='{$key}' value='{$val}'/>";
            }
        }
    }
    print "</form>";
    $recherche_ajax_mode = 0;
    $nb = 0;
    if ($resultat) {
        while ($r = pmb_mysql_fetch_object($resultat)) {
            $requete2 = "SELECT expl_bulletin FROM exemplaires WHERE expl_id='" . $r->expl_id . "'";
            $res = pmb_mysql_query($requete2);
            if ($res && pmb_mysql_num_rows($res) && pmb_mysql_result($res, 0, 0)) {
                $nt = new mono_display_expl('', $r->expl_id, 6, $sc->link_bulletin, $option_show_expl, $sc->link_expl_bull, '', $sc->link_explnum, 1, 0, 1, !$option_show_notice_fille, "", 1);
            } else {
                $nt = new mono_display_expl('', $r->expl_id, 6, $sc->link, $option_show_expl, $sc->link_expl, '', $sc->link_explnum, 1, 0, 1, !$option_show_notice_fille, "", 1);
            }
            echo "<div class='row'>" . $nt->result . $aff . "</div>";
        }
    }
    //Gestion de la pagination
    if ($nb_results) {
        $n_max_page = ceil($nb_results / $nb_per_page_search);
        if (!$page) {
            $page_en_cours = 0;
        } else {
            $page_en_cours = $page;
        }
        // affichage du lien précédant si nécessaire
        if ($page > 0) {
            $nav_bar .= "<a href='#' onClick='document.search_form.page.value-=1; ";
            if (!$hidden_form) {
                $nav_bar .= "document.search_form.launch_search.value=1; ";
            }
            $nav_bar .= "document.search_form.submit(); return false;'>";
            $nav_bar .= "<img src='./images/left.gif' border='0'  title='" . $msg[48] . "' alt='[" . $msg[48] . "]' hspace='3' align='middle'/>";
            $nav_bar .= "</a>";
        }
        $deb = $page_en_cours - 10;
        if ($deb < 0) {
            $deb = 0;
        }
        for ($i = $deb; $i < $n_max_page && $i < $page_en_cours + 10; $i++) {
            if ($i == $page_en_cours) {
                $nav_bar .= "<strong>" . ($i + 1) . "</strong>";
            } else {
                $nav_bar .= "<a href='#' onClick=\"if ((isNaN(document.search_form.page.value))||(document.search_form.page.value=='')) document.search_form.page.value=1; else document.search_form.page.value=" . $i . "; ";
                if (!$hidden_form) {
                    $nav_bar .= "document.search_form.launch_search.value=1; ";
                }
                $nav_bar .= "document.search_form.submit(); return false;\">";
                $nav_bar .= $i + 1;
                $nav_bar .= "</a>";
            }
            if ($i < $n_max_page) {
                $nav_bar .= " ";
            }
        }
        if ($page + 1 < $n_max_page) {
            $nav_bar .= "<a href='#' onClick=\"if ((isNaN(document.search_form.page.value))||(document.search_form.page.value=='')) document.search_form.page.value=1; else document.search_form.page.value=parseInt(document.search_form.page.value)+parseInt(1); ";
            if (!$hidden_form) {
                $nav_bar .= "document.search_form.launch_search.value=1; ";
            }
            $nav_bar .= "document.search_form.submit(); return false;\">";
            $nav_bar .= "<img src='./images/right.gif' border='0' title='" . $msg[49] . "' alt='[" . $msg[49] . "]' hspace='3' align='middle'>";
            $nav_bar .= "</a>";
        } else {
            $nav_bar .= "";
        }
        $nav_bar = "<div align='center'>{$nav_bar}</div>";
        echo $nav_bar;
    }
}
     exit;
 }
 // controle sur le nouveau code barre si applicable :
 if ($org_cb != $f_ex_cb) {
     // si le nouveau code-barre est deja utilise, on reste sur l'ancien
     $requete = "SELECT expl_id FROM exemplaires WHERE expl_cb='{$f_ex_cb}'";
     $myQuery = pmb_mysql_query($requete, $dbh);
     if (!($result = pmb_mysql_result($myQuery, 0, 0))) {
         $expl_cb = $f_ex_cb;
     } else {
         // Verif si expl_id est celui poste
         if ($expl_id == $result[0]) {
             $expl_cb = $org_cb;
         } else {
             //Erreur: code barre deja existant
             error_message_history($msg[301], $msg[303], 1);
             exit;
         }
     }
 } else {
     $expl_cb = $f_ex_cb;
 }
 // on prepare la date de creation ou modification
 $expl_date = today();
 // on recupere les valeurs
 $formlocid = "f_ex_section" . $expl_location;
 $expl_section = ${$formlocid};
 if (!is_numeric($f_ex_nbparts) || !$f_ex_nbparts) {
     $f_ex_nbparts = 1;
 }
 $transfert_origine = "";
 function elt_list()
 {
     global $msg, $charset;
     global $elt_query;
     global $results_show_all;
     $research .= '<b>' . htmlentities($msg['selector_lib_abt'], ENT_QUOTES, $charset) . '</b>&nbsp;' . htmlentities(stripslashes($elt_query), ENT_QUOTES, $charset);
     $this->show_form();
     if ($this->nbresults) {
         $research .= " => " . sprintf($msg["searcher_results"], $this->nbresults);
         if (!$results_show_all && $this->nbepage != 1) {
             $research .= "&nbsp;&nbsp;&nbsp;<input type='button' class='bouton_small' onclick='results_show_all();' name='searcher_results_show_all' value='" . htmlentities($msg['searcher_results_show_all'], ENT_QUOTES, $charset) . "'>";
         }
         $this->elt_b_list = str_replace('!!research!!', $research, $this->elt_b_list);
         print $this->elt_b_list;
         //Boutons check/uncheck/add selection
         print "<div class='row'>\n\t\t\t\t\t\t<input type='button' class='bouton_small' onclick='check_uncheck(1);' id='searcher_results_check_all' name='searcher_results_check_all' value='" . htmlentities($msg['searcher_results_check_all'], ENT_QUOTES, $charset) . "'>\n\t\t\t\t\t\t&nbsp;&nbsp;\n\t\t\t\t\t\t<input type='button' class='bouton_small' onclick='add_selection();' id='searcher_results_add_selection' name='searcher_results_add_selection' value='" . htmlentities($msg['searcher_results_add_selection'], ENT_QUOTES, $charset) . "'>\n\t\t\t\t\t</div>";
         print "<form name='searcher_results_check_form'>";
         // on lance la requête
         while ($nz = pmb_mysql_fetch_object($this->t_query)) {
             // abonnement
             $abt = new sel_abt_display($nz->abt_id, $this->base_url, 'sel_searcher_select_');
             $abt->action = $this->action;
             $abt->action_values = $this->action_values;
             $abt->doForm();
             $list .= $this->elt_r_list;
             if (count($this->elt_r_list_values)) {
                 foreach ($this->elt_r_list_values as $v) {
                     $list = str_replace("!!{$v}!!", $abt->{$v}, $list);
                 }
             }
         }
         print $list;
         // fin de liste
         print "</form>";
         print $this->elt_e_liste;
         print $this->back_script;
         print $this->back_script_show_all;
     } else {
         error_message_history($msg[357], $msg[1915], 1);
     }
 }
示例#8
0
            exit;
        }
    }
    if ($qt->quota_type["MAX"] && $default_value > $max_value && $max_value * 1 != 0) {
        error_message_history($msg["quotas_error"], $msg["quotas_error_default_gt_max"], 1);
        exit;
    }
    if ($qt->quota_type["MIN"] && $default_value < $min_value && $min_value * 1 != 0) {
        error_message_history($msg["quotas_error"], $msg["quotas_error_default_lt_min"], 1);
        exit;
    }
    $already = array();
    for ($i = 0; $i < count($elements); $i++) {
        $as = array_search($conflict_list[$i], $already);
        if ($as !== NULL && $as !== FALSE) {
            error_message_history($msg["quotas_error_order"], sprintf($msg["quotas_error_order_detail"], count($elements)), 1);
            exit;
        } else {
            $already[] = $conflict_list[$i];
        }
    }
}
//Enregistrement des éléments dans la base
$recorded = "";
if ($first == 1) {
    //Nettoyage
    $requete = "delete from " . $qt->table . " where quota_type=" . $qt->quota_type["ID"] . " and constraint_type in ('MIN','MAX','DEFAULT','CONFLICT','PRIORITY','FORCE_LEND','MAX_QUOTA')";
    mysql_query($requete);
    //Max
    $requete = "insert into " . $qt->table . " (quota_type,constraint_type,elements,value) values(" . $qt->quota_type["ID"] . ",'MAX',0,'" . $max_value . "')";
    mysql_query($requete);
示例#9
0
 static function save(&$demande)
 {
     global $dbh, $pmb_type_audit;
     if ($demande->id_demande) {
         //MODIFICATION
         $query = "UPDATE demandes SET\n\t\t\tsujet_demande='" . $demande->sujet_demande . "',\r\n\t\t\tnum_demandeur='" . $demande->num_demandeur . "',\r\n\t\t\tdate_demande='" . $demande->date_demande . "',\r\n\t\t\tdeadline_demande='" . $demande->deadline_demande . "',\r\n\t\t\tdate_prevue='" . $demande->date_prevue . "',\r\n\t\t\tprogression='" . $demande->progression . "',\r\n\t\t\ttitre_demande='" . $demande->titre_demande . "',\r\n\t\t\ttype_demande='" . $demande->type_demande . "',\r\n\t\t\ttheme_demande='" . $demande->theme_demande . "',\n\t\t\tnum_user_cloture='" . $demande->num_user_cloture . "',\n\t\t\tnum_linked_notice = '" . $demande->get_num_linked_notice() . "'\r\n\t\t\tWHERE id_demande='" . $demande->id_demande . "'";
         pmb_mysql_query($query, $dbh);
         if ($pmb_type_audit) {
             audit::insert_modif(AUDIT_DEMANDE, $demande->id_demande);
         }
     } else {
         //On ajoute une notice ?
         self::save_notice($demande);
         //CREATION de la demande
         $query = "INSERT INTO demandes SET\n\t\t\tsujet_demande='" . $demande->sujet_demande . "',\r\n\t\t\tetat_demande='" . $demande->etat_demande . "',\r\n\t\t\tnum_demandeur='" . $demande->num_demandeur . "',\r\n\t\t\tdate_demande='" . $demande->date_demande . "',\r\n\t\t\tdate_prevue='" . $demande->date_prevue . "',\r\n\t\t\tdeadline_demande='" . $demande->deadline_demande . "',\r\n\t\t\tprogression='" . $demande->progression . "',\r\n\t\t\ttitre_demande='" . $demande->titre_demande . "',\r\n\t\t\ttype_demande='" . $demande->type_demande . "',\r\n\t\t\ttheme_demande='" . $demande->theme_demande . "',\r\n\t\t\tnum_notice='" . $demande->num_notice . "',\n\t\t\tdmde_read_opac='1',\n\t\t\tnum_linked_notice = '" . $demande->get_num_linked_notice() . "'";
         pmb_mysql_query($query, $dbh);
         $demande->id_demande = pmb_mysql_insert_id($dbh);
         if ($pmb_type_audit) {
             audit::insert_creation(AUDIT_DEMANDE, $demande->id_demande);
         }
     }
     //Vérification des champs personalisés
     $p_perso = new parametres_perso("demandes");
     $nberrors = $p_perso->check_submited_fields();
     if ($nberrors) {
         error_message_history("", $p_perso->error_message, 1);
     } else {
         //Insertion des champs personalisés
         $p_perso->rec_fields_perso($demande->id_demande);
     }
     //MAJ des users de la demande
     self::save_demandes_users($demande);
 }
示例#10
0
                }
            } else {
                $integrate = false;
            }
            if ($integrate == false || $force == 1) {
                $z = new z3950_notice("unimarc", $infos['notice'], $infos['source_id']);
                $z->libelle_form = isset($notice_id) ? $msg[notice_connecteur_remplace_catal] : '';
                if ($z->bibliographic_level == "a" && $z->hierarchic_level == "2") {
                    $form = $z->get_form("catalog.php?categ=search&mode=7&sub=integre&action=record" . $notice_id_info . "&item={$item}", 0, 'button', true);
                } else {
                    $form = $z->get_form("catalog.php?categ=search&mode=7&sub=integre&action=record" . $notice_id_info . "&item={$item}", 0, 'button');
                }
                if (isset($notice_id)) {
                    $form = str_replace("<!--!!form_title!!-->", "<h3>" . sprintf($msg["notice_replace_external_action"], $notice_id, $item) . "</h3>", $form);
                } else {
                    $form = str_replace("<!--!!form_title!!-->", "<h3>" . sprintf($msg["connecteurs_integrate"], $item) . "</h3>", $form);
                }
                $form = str_replace("<!--form_suite-->", "<input type='hidden' name='serialized_search' value='" . htmlentities($sc->serialize_search(), ENT_QUOTES, $charset) . "'/><input type='hidden' name='page' value='" . htmlentities($page, ENT_QUOTES, $charset) . "'/>", $form);
                print $form;
            } else {
                $tab = new stdClass();
                $tab->POST = $_POST;
                $tab->GET = $_GET;
                $force_url = htmlentities(serialize($tab), ENT_QUOTES, $charset);
                print "<br /><br />\n\t\t\t\t<div class='erreur'>{$msg['540']}</div>\n\t\t\t\t\t<div class='row'>\n\t\t\t\t\t\t<div class='colonne10'>\n\t\t\t\t\t\t\t<img src='./images/error.gif' align='left'>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div class='colonne80'>\n\t\t\t\t\t\t\t<strong>" . $msg['external_notice_already_integrate'] . "</strong>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div class='row'>{$notice_display}</div>\n\t\t\t\t\t<script src='{$javascript_path}/tablist.js'></script>\n\t\t\t\t\t<div class='row'>\n\t\t\t\t\t\t<form class='form-{$current_module}' name='dummy' method='post' action='./catalog.php?categ=search&mode=7&sub=integre&item={$item}&force=1'>\n\t\t\t\t\t\t\t<input type='hidden' name='serialized_search' value='" . htmlentities($sc->serialize_search(), ENT_QUOTES, $charset) . "'/>\n\t\t\t\t\t\t\t<input type='button' name='ok' class='bouton' value=\" " . $msg['external_integrate_back'] . " \" onClick='history.go(-1);'>\n\t\t\t\t\t\t\t<input type='submit' name='force_button' class='bouton' value=\" " . $msg['external_force_integration'] . " \">\n\t\t\t\t\t\t</form>\n\t\t\t\t\t\t<script type='text/javascript'>document.forms['dummy'].elements['ok'].focus();</script>\n\t\t\t\t\t</div>\n\t\t\t\t</div>";
            }
        } else {
            error_message_history($msg["connecteurs_unable_to_convert_title"], $msg["connecteurs_unable_to_convert"], 1);
        }
        break;
}
示例#11
0
 if (!$page) {
     $page = 1;
 }
 $debut = ($page - 1) * $nb_per_page;
 $requete = "select count(1) from {$table}";
 $res = mysql_query($requete);
 if ($res) {
     $nbr_lignes = mysql_result($res, 0, 0);
 } else {
     $nbr_lignes = 0;
 }
 if ($nbr_lignes) {
     $requete = "select {$table}.* from " . $table . ", empr where empr.id_empr={$table}.id_empr";
     //Y-a-t-il une erreur lors de la recherche ?
     if ($sc->error_message) {
         error_message_history("", $sc->error_message, 1);
         exit;
     }
     print $sc->make_hidden_search_form($url, "form_filters");
     $res = mysql_query($requete, $dbh);
     $human_requete = $sc->make_human_query();
     print "<strong>" . $msg["search_search_emprunteur"] . "</strong> : " . $human_requete;
     if ($nbr_lignes) {
         print " => " . $nbr_lignes . " " . $msg["search_empr_nb_result"] . "<br />\n";
         $tab_id_empr = array();
         while ($row = mysql_fetch_object($res)) {
             $tab_id_empr[] = $row->id_empr;
         }
         $clause = "WHERE id_empr in('" . implode("','", $tab_id_empr) . "')";
     } else {
         print "<br />" . $msg["1915"] . " ";
示例#12
0
 case 'update':
     if ($retard_periodicite >= $seuil_periodicite || $retard_periodicite == 0) {
         if ($id) {
             $requete = "UPDATE abts_periodicites SET libelle='{$libelle}',duree='{$duree}',unite='{$unite}', seuil_periodicite='{$seuil_periodicite}', retard_periodicite='{$retard_periodicite}', retard_periodicite='{$retard_periodicite}' , consultation_duration='{$consultation_duration}' WHERE periodicite_id='{$id}' ";
             $res = mysql_query($requete, $dbh);
             show_statut($dbh);
         } else {
             $requete1 = mysql_query("SELECT count(*) FROM abts_periodicites WHERE libelle='{$libelle}'");
             if ($requete1) {
                 $result1 = mysql_fetch_array($requete1);
                 if ($result1[0] == 0) {
                     $requete = "INSERT INTO abts_periodicites SET libelle='{$libelle}',duree='{$duree}',unite='{$unite}', seuil_periodicite='{$seuil_periodicite}', retard_periodicite='{$retard_periodicite}' , consultation_duration='{$consultation_duration}' ";
                     $res = mysql_query($requete, $dbh);
                     show_statut($dbh);
                 } else {
                     error_message_history($msg[periodicite_existante], $msg[periodicite_existante], 1);
                 }
                 mysql_free_result($requete1);
             } else {
                 print $msg['err_sql'] . "\n";
                 print mysql_error();
             }
         }
     } else {
         error_message($msg[retard_rapport_seuil], $msg[retard_rapport_seuil], 1, 'admin.php?categ=abonnements&sub=periodicite&action=');
     }
     break;
 case 'add':
     if (empty($libelle)) {
         statut_form();
     } else {
示例#13
0
 case 'modif':
     break;
 case 'update':
     if ($req_name && $req_code) {
         $requete = "SELECT count(1) FROM procs WHERE name='" . $req_name . "' ";
         $res = mysql_query($requete, $dbh);
         $nbr_lignes = mysql_result($res, 0, 0);
         if (!$nbr_lignes) {
             if (is_array($user_aut)) {
                 $autorisations = implode(" ", $user_aut);
             } else {
                 $autorisations = '';
             }
             $param_name = check_param($req_code);
             if ($param_name !== true) {
                 error_message_history($param_name, sprintf($msg['proc_param_check_field_name'], $param_name), 1);
                 exit;
             }
             $requete = "INSERT INTO procs (idproc,name,requete,comment,autorisations,num_classement) VALUES ('', '{$req_name}', '{$req_code}', '{$req_comm}', '{$autorisations}', '{$form_classement}'  ) ";
             $res = mysql_query($requete, $dbh);
         } else {
             print "<script language='Javascript'>alert(\"" . addslashes($msg[709]) . "\");</script>";
         }
         print "<script type='text/javascript'> document.location='./admin.php?categ=proc&sub=proc&action='</script>";
     }
     break;
 case 'del':
     break;
 case 'list':
 default:
     break;
示例#14
0
                        }
                        // fin if autre procédure
                    }
                }
                $error_message = "";
                print sprintf($msg["caddie_action_flag_processed"], $nb_elements_flag) . "<br />";
                print sprintf($msg["caddie_action_no_flag_processed"], $nb_elements_no_flag) . "<br />";
                print "<b>" . sprintf($msg["caddie_action_total_processed"], $nb_elements_no_flag + $nb_elements_flag) . "</b><br /><br />";
                if ($error_message_flag) {
                    $error_message .= sprintf($msg["caddie_action_error"], $error_message_flag) . "<br />";
                }
                if ($error_message_no_flag) {
                    $error_message .= sprintf($msg["caddie_action_error"], $error_message_no_flag);
                }
                if ($error_message) {
                    error_message_history($msg["caddie_action_invalid_query"], $error_message, 1);
                    exit;
                }
            }
            print aff_cart_nb_items($myCart);
            echo "<hr /><input type='button' class='bouton' value='" . $msg["caddie_select_reindex"] . "' onclick='document.location=&quot;./catalog.php?categ=caddie&amp;sub=action&amp;quelle=reindex&amp;action=suite&amp;idcaddie=" . $idcaddie . "&amp;elt_flag=" . $elt_flag . "&amp;elt_no_flag=" . $elt_no_flag . "&quot;' />";
            echo "<input type='button' class='bouton' value='" . $msg["caddie_menu_action_suppr_panier"] . "' onclick='document.location=&quot;./catalog.php?categ=caddie&amp;sub=action&amp;quelle=supprpanier&amp;action=choix_quoi&amp;object_type=NOTI&amp;idcaddie=" . $idcaddie . "&amp;item=0&amp;elt_flag=" . $elt_flag . "&amp;elt_no_flag=" . $elt_no_flag . "&quot;' />";
            break;
        default:
            print aff_cart_nb_items($myCart);
            print $cart_choix_quoi_action;
            show_procs($idcaddie);
            break;
    }
} else {
    aff_paniers($idcaddie, "NOTI", "./catalog.php?categ=caddie&sub=action&quelle=selection", "", $msg["caddie_select_for_action"], "", 0, 0, 0);
示例#15
0
 function show_results_fichier($url, $url_to_search_form, $hidden_form = true, $search_target = "", $acces = false)
 {
     global $dbh;
     global $begin_result_liste;
     global $nb_per_page_search;
     global $page, $dest;
     global $charset;
     global $search;
     global $msg;
     global $pmb_nb_max_tri;
     global $affich_tris_result_liste;
     global $pmb_allow_external_search;
     global $debug;
     global $gestion_acces_active, $gestion_acces_user_notice, $PMBuserid, $pmb_allow_external_search;
     global $link_bulletin;
     $start_page = $nb_per_page_search * $page;
     //Y-a-t-il des champs ?
     if (count($search) == 0) {
         error_message_history($msg["search_empty_field"], $msg["search_no_fields"], 1);
         exit;
     }
     //Verification des champs vides
     for ($i = 0; $i < count($search); $i++) {
         $op = "op_" . $i . "_" . $search[$i];
         global ${$op};
         $field_ = "field_" . $i . "_" . $search[$i];
         global ${$field_};
         $field = ${$field_};
         $s = explode("_", $search[$i]);
         $bool = false;
         if ($s[0] == "f") {
             $champ = $this->fixedfields[$s[1]]["TITLE"];
             if ((string) $field[0] == "") {
                 $bool = true;
             }
         } elseif (array_key_exists($s[0], $this->pp)) {
             $champ = $this->pp[$s[0]]->t_fields[$s[1]]["TITRE"];
             if ((string) $field[0] == "") {
                 $bool = true;
             }
         } elseif ($s[0] == "s") {
             $champ = $this->specialfields[$s[1]]["TITLE"];
             $type = $this->specialfields[$s[1]]["TYPE"];
             for ($is = 0; $is < count($this->tableau_speciaux["TYPE"]); $is++) {
                 if ($this->tableau_speciaux["TYPE"][$is]["NAME"] == $type) {
                     $sf = $this->specialfields[$s[1]];
                     global $include_path;
                     require_once $include_path . "/search_queries/specials/" . $this->tableau_speciaux["TYPE"][$is]["PATH"] . "/search.class.php";
                     $specialclass = new $this->tableau_speciaux["TYPE"][$is]["CLASS"]($s[1], $sf, $i, $this);
                     $bool = $specialclass->is_empty($field);
                     break;
                 }
             }
         }
         if ($bool && !$this->op_empty[${$op}]) {
             error_message_history($msg["search_empty_field"], sprintf($msg["search_empty_error_message"], $champ), 1);
             exit;
         }
     }
     $table = $this->make_search();
     if ($acces == true && $gestion_acces_active == 1 && $gestion_acces_user_notice == 1) {
         $this->filter_searchtable_from_accessrights($table, $PMBuserid);
     }
     $requete = "select count(1) from {$table}";
     $nb_results = pmb_mysql_result(pmb_mysql_query($requete), 0, 0);
     //Y-a-t-il une erreur lors de la recherche ?
     if ($this->error_message) {
         error_message_history("", $this->error_message, 1);
         exit;
     }
     if (!$dest && $hidden_form) {
         print $this->make_hidden_search_form($url, "search_form", "", false);
         print "<input type='hidden' name='dest' value='' />\n";
         print "</form>\n";
     }
     if ($dest != "TABLEAU") {
         $human_requete = $this->make_human_query();
         print "<strong>" . $msg["search_search_extended"] . "</strong> : " . $human_requete;
         if ($debug) {
             print "<br />" . $this->serialize_search();
         }
         if ($nb_results) {
             print " => " . $nb_results . " " . $msg["fiche_found"] . "<br />\n";
         } else {
             print "<br />" . $msg["1915"] . " ";
         }
     }
     $requete = "select {$table}.* from " . $table . ",fiche where fiche.id_fiche={$table}.id_fiche";
     if (!$dest) {
         $requete .= " limit " . $start_page . "," . $nb_per_page_search;
     }
     $resultat = pmb_mysql_query($requete, $dbh);
     if (pmb_mysql_num_rows($resultat)) {
         $result_fic = array();
         $fic = new fiche();
         while ($r = pmb_mysql_fetch_object($resultat)) {
             $result_fic[$r->id_fiche] = $fic->get_values($r->id_fiche, 1);
         }
         if ($result_fic) {
             if ($dest == "TABLEAUHTML") {
                 print "<div class='row'>" . $fic->display_results_tableau($result_fic, "", 0, true) . "</div>";
             } elseif ($dest == "TABLEAU") {
                 $fic->print_results_tableau($result_fic);
             } else {
                 print "<div class='row'>" . $fic->display_results_tableau($result_fic) . "</div>";
             }
         }
     }
     if ($this->limited_search) {
         $limit_script = "&limited_search=1";
     } else {
         $limit_script = "";
     }
     if (!$dest) {
         print "<div class='row'><input type='button' class='bouton' onClick=\"document.search_form.dest.value=''; document.search_form.action='{$url_to_search_form}{$limit_script}'; document.search_form.target='{$search_target}'; document.search_form.submit(); return false;\" value=\"" . $msg["search_back"] . "\"/>";
         print "<font size='4'>&nbsp;&nbsp;&nbsp;&nbsp;</font>\n\t\t\t<input type='image' src='./images/tableur.gif' border='0' onClick=\"document.search_form.dest.value='TABLEAU'; document.search_form.submit(); \" alt='" . htmlentities($msg["fiche_export_excel"], ENT_QUOTES, $charset) . "' title='" . htmlentities($msg["fiche_export_excel"], ENT_QUOTES, $charset) . "' />\n\t\t\t<font size='4'>&nbsp;&nbsp;&nbsp;&nbsp;</font>\n\t\t\t<input type='image' src='./images/tableur_html.gif' border='0' onClick=\"document.search_form.dest.value='TABLEAUHTML'; document.search_form.submit(); \" alt='" . htmlentities($msg["fiche_export_tableau"], ENT_QUOTES, $charset) . "' title='" . htmlentities($msg["fiche_export_tableau"], ENT_QUOTES, $charset) . "' /></div>";
     }
     //Gestion de la pagination
     if ($nb_results && !$dest) {
         $n_max_page = ceil($nb_results / $nb_per_page_search);
         if (!$page) {
             $page_en_cours = 0;
         } else {
             $page_en_cours = $page;
         }
         // affichage du lien precedent si necessaire
         if ($page > 0) {
             $nav_bar .= "<a href='#' onClick='document.search_form.dest.value=\"\"; document.search_form.page.value-=1; ";
             if (!$hidden_form) {
                 $nav_bar .= "document.search_form.launch_search.value=1; ";
             }
             $nav_bar .= "document.search_form.submit(); return false;'>";
             $nav_bar .= "<img src='./images/left.gif' border='0'  title='" . $msg[48] . "' alt='[" . $msg[48] . "]' hspace='3' align='middle'/>";
             $nav_bar .= "</a>";
         }
         $deb = $page_en_cours - 10;
         if ($deb < 0) {
             $deb = 0;
         }
         for ($i = $deb; $i < $n_max_page && $i < $page_en_cours + 10; $i++) {
             if ($i == $page_en_cours) {
                 $nav_bar .= "<strong>" . ($i + 1) . "</strong>";
             } else {
                 $nav_bar .= "<a href='#' onClick=\"if ((isNaN(document.search_form.page.value))||(document.search_form.page.value=='')) document.search_form.page.value=1; else document.search_form.page.value=" . $i . "; ";
                 if (!$hidden_form) {
                     $nav_bar .= "document.search_form.launch_search.value=1; ";
                 }
                 $nav_bar .= "document.search_form.dest.value=''; document.search_form.submit(); return false;\">";
                 $nav_bar .= $i + 1;
                 $nav_bar .= "</a>";
             }
             if ($i < $n_max_page) {
                 $nav_bar .= " ";
             }
         }
         if ($page + 1 < $n_max_page) {
             $nav_bar .= "<a href='#' onClick=\"if ((isNaN(document.search_form.page.value))||(document.search_form.page.value=='')) document.search_form.page.value=1; else document.search_form.page.value=parseInt(document.search_form.page.value)+parseInt(1); ";
             if (!$hidden_form) {
                 $nav_bar .= "document.search_form.launch_search.value=1; ";
             }
             $nav_bar .= "document.search_form.dest.value=''; document.search_form.submit(); return false;\">";
             $nav_bar .= "<img src='./images/right.gif' border='0' title='" . $msg[49] . "' alt='[" . $msg[49] . "]' hspace='3' align='middle'>";
             $nav_bar .= "</a>";
         } else {
             $nav_bar .= "";
         }
         $nav_bar = "<div align='center'>{$nav_bar}</div>";
         echo $nav_bar;
     }
 }
 function make_error($message)
 {
     global $msg;
     error_message_history($msg["540"], $message, 1);
     exit;
 }
示例#17
0
 $hp = new parameters($id, "empr_caddie_procs");
 $hp->get_final_query();
 echo "<hr />" . $hp->final_query . "<hr />";
 $line = pmb_split("\n", $hp->final_query);
 $nb_element_avant = $myCart->nb_item;
 while (list($cle, $valeur) = each($line)) {
     if ($valeur != '') {
         if (pmb_strtolower(pmb_substr($valeur, 0, 6)) == "select" || pmb_strtolower(pmb_substr($valeur, 0, 6)) == "create") {
         } else {
             echo pmb_substr($valeur, 0, 6);
             error_message_history($msg['caddie_action_invalid_query'], $msg['requete_selection'], 1);
             exit;
         }
         $result_selection = mysql_query($valeur, $dbh);
         if (!$result_selection) {
             error_message_history($msg['caddie_action_invalid_query'], $msg['requete_echouee'] . mysql_error(), 1);
             exit;
         }
         if (pmb_strtolower(pmb_substr($valeur, 0, 6)) == "select") {
             $nb_element_a_ajouter += mysql_num_rows($result_selection);
             if (mysql_num_rows($result_selection)) {
                 while ($obj_selection = mysql_fetch_object($result_selection)) {
                     $myCart->add_item($obj_selection->object_id);
                 }
             }
             // fin if mysql_num_rows
             $myCart->compte_items();
         }
         // fin if rqt sélection
     }
     //fin valeur nonvide
示例#18
0
    $_SESSION["param_export"]["notice_exporte"] = "";
    $_SESSION["param_export"]["bulletin_exporte"] = "";
    //On enregistre les variables postées dans la session
    export_param::init_session();
    if ($output_params["SPECIALDOCTYPE"] == "yes") {
        if ($liste[0]) {
            $output_params["DOCTYPE"] = mysql_result(mysql_query("select typdoc from notices where notice_id='" . $liste[0] . "'"), 0, 0);
        }
    }
    $fo = fopen("{$base_path}/temp/" . $file_out, "w+");
    //Entête
    @fwrite($fo, _get_header_($output_params));
    fclose($fo);
}
if ($n_notices == 0) {
    error_message_history($msg["export_no_notice_found"], $msg["export_no_notice_for_criterias"], 1);
    exit;
}
//Affichage de la progression
$percent = @round($n_current / $n_notices * 100);
if ($percent == 0) {
    $percent = 1;
}
echo "<center><h3>" . $msg["export_running"] . "</h3></center><br />\n";
echo "<table align=center width=100%><tr><td style=\"border-width:1px;border-style:solid;border-color:#FFFFFF;\" width=100%><img src=\"{$base_path}/images/jauge.png\" width=\"" . $percent . "%\" height=\"16\"></td></tr><tr><td ><center>" . round($percent) . "%</center></td></tr></table>\n";
echo "<center>" . sprintf($msg["export_progress"], $n_current, $n_notices, $n_notices - $n_current) . "</center>";
//Début d'export du lot
//Recherche du no_notice le plus grand
$requete = "select max(no_notice) from import_marc where origine='{$origine}'";
$resultat = mysql_query($requete);
$no_notice = mysql_result($resultat, 0, 0) * 1 + 1;
示例#19
0
    $n_current = 0;
    //Nombre d'erreurs = 0;
    $n_errors = 0;
    //Création du fichier de sortie
    $f = explode(".", $file_in);
    if (count($f) > 1) {
        unset($f[count($f) - 1]);
    }
    $file_out = implode(".", $f) . "." . $output_params['SUFFIX'] . "~";
    $fo = fopen("{$base_path}/temp/" . $file_out, "w+");
    //Ouverture du fichier d'origine
    $fi = fopen("{$base_path}/temp/" . $file_in, "r");
    //Récupération du nombre de notices et enregistrement dans la base de données des notices
    $index = _get_n_notices_($fi, "{$base_path}/temp/" . $file_in, $input_params, $origine);
    if (count($index) == 0) {
        error_message_history($msg["ie_empty_file"], sprintf($msg["ie_empty_file_detail"], $import_type_l), 1);
        exit;
    }
    //Entête
    @fwrite($fo, _get_header_($output_params));
    fclose($fo);
    //Vidage de la table de log
    //mysql_query("delete from error_log where error_origin='convert.log'");
}
function convert_notice($notice, $encoding)
{
    global $step;
    global $param_path;
    global $n_errors;
    global $message_convert;
    global $n_current;
示例#20
0
 function show_results($url, $url_to_search_form, $hidden_form = true, $search_target = "")
 {
     global $dbh;
     global $begin_result_liste;
     global $opac_search_results_per_page;
     $nb_per_page_search = $opac_search_results_per_page;
     global $page;
     global $charset;
     global $search;
     global $msg, $opac_notices_depliable;
     global $debug;
     $start_page = $nb_per_page_search * $page;
     //Y-a-t-il des champs ?
     if (count($search) == 0) {
         error_message_history($msg["search_empty_field"], $msg["search_no_fields"], 1);
         exit;
     }
     //Verification des champs vides
     for ($i = 0; $i < count($search); $i++) {
         $op = "op_" . $i . "_" . $search[$i];
         global ${$op};
         $field_ = "field_" . $i . "_" . $search[$i];
         global ${$field_};
         $field = ${$field_};
         $s = explode("_", $search[$i]);
         $bool = false;
         if ($s[0] == "f") {
             $champ = $this->fixedfields[$s[1]]["TITLE"];
             if ((string) $field[0] == "") {
                 $bool = true;
             }
         } elseif (array_key_exists($s[0], $this->pp)) {
             $champ = $this->pp[$s[0]]->t_fields[$s[1]]["TITRE"];
             if ((string) $field[0] == "") {
                 $bool = true;
             }
         } elseif ($s[0] == "s") {
             $champ = $this->specialfields[$s[1]]["TITLE"];
             $type = $this->specialfields[$s[1]]["TYPE"];
             for ($is = 0; $is < count($this->tableau_speciaux["TYPE"]); $is++) {
                 if ($this->tableau_speciaux["TYPE"][$is]["NAME"] == $type) {
                     $sf = $this->specialfields[$s[1]];
                     global $include_path;
                     require_once $include_path . "/search_queries/specials/" . $this->tableau_speciaux["TYPE"][$is]["PATH"] . "/search.class.php";
                     $specialclass = new $this->tableau_speciaux["TYPE"][$is]["CLASS"]($s[1], $sf, $i, $this);
                     $bool = $specialclass->is_empty($field);
                     break;
                 }
             }
         } elseif (substr($s, 0, 9) == "authperso") {
         }
         if ($bool && !$this->op_empty[${$op}]) {
             error_message_history($msg["search_empty_field"], sprintf($msg["search_empty_error_message"], $champ), 1);
             exit;
         }
     }
     $table = $this->make_search();
     //Y-a-t-il une erreur lors de la recherche ?
     if ($this->error_message) {
         error_message_history("", $this->error_message, 1);
         exit;
     }
     if ($hidden_form) {
         print $this->make_hidden_search_form($url);
     }
     $requete = "select count(1) from {$table}";
     $nb_results = pmb_mysql_result(pmb_mysql_query($requete), 0, 0);
     /*
     		 $requete="select $table.*,notices.niveau_biblio from ".$table.",notices where notices.notice_id=$table.notice_id order by notices.index_sew limit ".$start_page.",".$nb_per_page_search;
     		$resultat=pmb_mysql_query($requete,$dbh);*/
     print pmb_bidi("<strong>" . $msg["search_search_extended"] . "</strong> : " . $this->make_human_query());
     if ($nb_results) {
         print " => " . $nb_results . " " . $msg["1916"] . "<br />\n";
         if ($opac_notices_depliable) {
             print $begin_result_liste;
         }
     } else {
         print "<br />" . $msg["1915"] . " ";
     }
     print "<input type='button' class='bouton' onClick=\"document.search_form.action='{$url_to_search_form}'; document.search_form.target='{$search_target}'; document.search_form.submit(); return false;\" value=\"" . $msg["search_back"] . "\"/>";
     while ($r = pmb_mysql_fetch_object($resultat)) {
         if ($r->niveau_biblio != 's' && $r->niveau_biblio != 'a') {
             // notice de monographie
             $nt = new mono_display($r->notice_id, 6, $this->link, 1, $this->link_expl, '', $this->link_explnum, 1);
         } else {
             // on a affaire a un periodique
             $nt = new serial_display($r->notice_id, 6, $this->link_serial, $this->link_analysis, $this->link_bulletin, "", $this->link_explnum_serial, 0);
         }
         echo pmb_bidi("<div class='row'>" . $nt->result . "</div>");
     }
     //Gestion de la pagination
     if ($nb_results) {
         print $this->get_current_search_map();
         $n_max_page = ceil($nb_results / $nb_per_page_search);
         echo "<div align='center'>";
         if ($page > 0) {
             echo "<a href='#' onClick='document.search_form.page.value-=1; ";
             if (!$hidden_form) {
                 echo "document.search_form.launch_search.value=1; ";
             }
             echo "document.search_form.submit(); return false;'>";
             echo "<img src='./images/left.gif' border='0'  title='" . $msg["prec_page"] . "' alt='[" . $msg["prec_page"] . "]' hspace='3' align='middle'/>";
             echo "</a>";
         }
         echo "<strong>page " . ($page + 1) . "/" . $n_max_page . "</strong>";
         if ($page + 1 < $n_max_page) {
             echo "<a href='#' onClick=\"if ((isNaN(document.search_form.page.value))||(document.search_form.page.value=='')) document.search_form.page.value=1; else document.search_form.page.value=parseInt(document.search_form.page.value)+parseInt(1); ";
             if (!$hidden_form) {
                 echo "document.search_form.launch_search.value=1; ";
             }
             echo "document.search_form.submit(); return false;\">";
             echo "<img src='./images/right.gif' border='0' title='" . $msg["next_page"] . "' alt='[" . $msg["next_page"] . "]' hspace='3' align='middle'>";
             echo "</a>";
         }
         echo "</div>";
     }
 }