$requete = "SELECT * FROM abts_abts WHERE abt_id='{$abt_id}'";
        $abtsQuery = pmb_mysql_query($requete, $dbh);
        if (pmb_mysql_num_rows($abtsQuery)) {
            $abts = pmb_mysql_fetch_object($abtsQuery);
            $expl->expl_cote = $abts->cote;
            $expl->expl_location = $abts->location_id;
            $expl->expl_section = $abts->section_id;
            $expl->expl_codestat = $abts->codestat_id;
            $expl->expl_typdoc = $abts->typdoc_id;
            $expl->expl_statut = $abts->statut_id;
            $expl->expl_owner = $abts->lender_id;
            $expl->type_antivol = $abts->type_antivol;
            $expl->expl_note = $abts->expl_note;
            $expl->expl_comment = $abts->expl_comment;
            $expl->expl_prix = $abts->expl_prix;
            $expl->destinataire = $abts->destinataire;
        }
        // sélection de la cote dewey de la notice chapeau pour pré-renseignement de la cote en création expl
        $query_cote = "select indexint_name from indexint, notices, bulletins where bulletin_id='{$bul_id}' and bulletin_notice=notice_id and notices.indexint=indexint.indexint_id ";
        $myQuery_cote = pmb_mysql_query($query_cote, $dbh);
        if (pmb_mysql_num_rows($myQuery_cote)) {
            $pre_cote = pmb_mysql_fetch_object($myQuery_cote);
            $expl->expl_cote = $pre_cote->indexint_name;
        }
    }
    $bull_form .= bul_do_form($expl);
    $templates = str_replace("!!form!!", $bull_form, $templates);
}
$templates = str_replace("!!serialcir_print!!", $serialcir_print, $templates);
$templates = str_replace("!!print_cote!!", $print_cote, $templates);
print $templates;
            print "impossible d'accéder à cet exemplaire.";
        }
    } else {
        // création d'un exemplaire
        // avant toute chose, on regarde si ce cb n'existe pas déjà
        $requete = "SELECT count(1) FROM exemplaires WHERE expl_cb='" . $noex . "' ";
        $myQuery = pmb_mysql_query($requete, $dbh);
        if (!pmb_mysql_result($myQuery, 0, 0)) {
            $expl = new stdClass();
            $expl->expl_cb = $noex;
            $expl->expl_id = 0;
            $expl->expl_bulletin = $bul_id;
            $expl->expl_location = $deflt_docs_location;
            $expl->expl_section = $deflt_docs_section;
            $expl->expl_codestat = $deflt_docs_codestat;
            $expl->expl_typdoc = $deflt_docs_type;
            $expl->expl_statut = $deflt_docs_statut;
            $expl->expl_owner = $deflt_lenders;
            $expl_create_date = '';
            $expl_update_date = '';
            $bulletin = new bulletinage($bul_id);
            $expl->expl_cote = prefill_cote($bulletin->bulletin_notice);
            print bul_do_form($expl);
        } else {
            print "<div class=\"row\"><div class=\"msg-perio\" size=\"+2\">" . $msg["expl_message_code_utilise"] . "</div></div>";
            print "<div class=\"row\"><a href=\"./catalog.php?categ=serials&sub=bulletinage&action=view&bul_id=";
            print $bulletinage->bul_id;
            print "\">Retour</a></div>";
        }
    }
}