• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP pmb_mysql_fetch_object函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中pmb_mysql_fetch_object函数的典型用法代码示例。如果您正苦于以下问题:PHP pmb_mysql_fetch_object函数的具体用法?PHP pmb_mysql_fetch_object怎么用?PHP pmb_mysql_fetch_object使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了pmb_mysql_fetch_object函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: genere_page_rss

function genere_page_rss($id = 0)
{
    global $dbh, $opac_url_base, $charset, $msg;
    global $opac_view_filter_class;
    if ($id) {
        $clause = " where id_rss_flux='{$id}' ";
    }
    $rqt = "select id_rss_flux, nom_rss_flux, img_url_rss_flux from rss_flux {$clause} order by 2 ";
    $res = pmb_mysql_query($rqt, $dbh);
    while ($obj = pmb_mysql_fetch_object($res)) {
        if ($opac_view_filter_class) {
            if (!$opac_view_filter_class->is_selected("flux_rss", $obj->id_rss_flux)) {
                continue;
            }
        }
        $liens .= "\n\t\t<tr>\n\t\t\t<td width=10%>";
        if ($obj->img_url_rss_flux) {
            $liens .= "<a href=\"index.php?lvl=rss_see&id=" . $obj->id_rss_flux . "\"><img src='" . $obj->img_url_rss_flux . "' border=none /></a>";
        }
        $liens .= "</td><td width=50%><a href=\"index.php?lvl=rss_see&id=" . $obj->id_rss_flux . "\">" . htmlentities($obj->nom_rss_flux, ENT_QUOTES, $charset) . "</a>\n\t\t\t</td><td><a href=\"" . $opac_url_base . "rss.php?id=" . $obj->id_rss_flux . "\" alt=\"" . $msg[abonne_rss_dispo] . "\" title=\"" . $msg[abonne_rss_dispo] . "\"><img id=\"rss_logo\" src='" . $opac_url_base . "images/rss.png' border=none /></a>\n\t\t\t" . htmlentities($opac_url_base . "rss.php?id=" . $obj->id_rss_flux, ENT_QUOTES, $charset) . "\n\t\t\t\t</td></tr>";
    }
    if ($liens) {
        $liens = "<table> {$liens} </table>";
    }
    return $liens;
}
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:26,代码来源:includes_rss.inc.php


示例2: get_rights

 function get_rights($group, $method)
 {
     global $msg;
     $this->clear_error();
     //Vérification que le groupe / méthode existe
     if (!$method && $this->es->group_exists($group) || $this->es->method_exists($group, $method)) {
         $es_r = new es_rights($group, $method);
         $requete = "select available, num_user, anonymous from es_methods, es_methods_users where groupe='" . addslashes($group) . "' and method='" . addslashes($method) . "' and id_method=num_method";
         $resultat = pmb_mysql_query($requete);
         if ($resultat) {
             $first = true;
             while ($r = pmb_mysql_fetch_object($resultat)) {
                 if ($first) {
                     $es_r->available = $r->available;
                 }
                 if ($r->anonymous) {
                     $es_r->anonymous_user = $r->num_user;
                 } else {
                     $es_r->users[] = $r->num_user;
                 }
             }
         }
         return $es_r;
     } else {
         $this->set_error(ES_RIGHTS_UNKNOWN_GROUP_OR_METHOD, $msg["es_rights_error_unknown_group"]);
         return false;
     }
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:28,代码来源:external_services_rights.class.php


示例3: fetch_datas

 public function fetch_datas()
 {
     global $dbh;
     $this->instruments = array();
     $this->instruments_data = array();
     $this->label = "";
     $this->num_nomenclature = 0;
     $this->order = 0;
     if ($this->id) {
         //le nom de l'atelier
         $query = "select * from nomenclature_workshops where id_workshop = " . $this->id . " order by workshop_order asc, workshop_label";
         $result = pmb_mysql_query($query, $dbh);
         if (pmb_mysql_num_rows($result)) {
             if ($row = pmb_mysql_fetch_object($result)) {
                 $this->label = $row->workshop_label;
                 $this->num_nomenclature = $row->workshop_num_nomenclature;
                 $this->order = $row->workshop_order;
                 //récupération des instruments
                 $query = "select workshop_instrument_num_instrument, workshop_instrument_number,workshop_instrument_order from nomenclature_workshops_instruments where workshop_instrument_num_workshop = " . $this->id . " order by workshop_instrument_order asc";
                 $result = pmb_mysql_query($query, $dbh);
                 if (pmb_mysql_num_rows($result)) {
                     while ($row = pmb_mysql_fetch_object($result)) {
                         $this->add_instrument(new nomenclature_instrument($row->workshop_instrument_num_instrument));
                         $this->instruments_data[$row->workshop_instrument_num_instrument]['effective'] = $row->workshop_instrument_number;
                         $this->instruments_data[$row->workshop_instrument_num_instrument]['order'] = $row->workshop_instrument_order;
                     }
                 }
             }
         }
     }
 }
开发者ID:hogsim,项目名称:PMB,代码行数:31,代码来源:nomenclature_workshop.class.php


示例4: param_perso_form

function param_perso_form(&$p_perso)
{
    global $dbh;
    global $param_perso_900;
    for ($i = 0; $i < count($param_perso_900); $i++) {
        $req = " select idchamp, type, datatype from notices_custom where name='" . $param_perso_900[$i]['n'] . "'";
        $res = pmb_mysql_query($req, $dbh);
        if (pmb_mysql_num_rows($res)) {
            $perso = pmb_mysql_fetch_object($res);
            if ($perso->idchamp) {
                if ($perso->type == 'list') {
                    $requete = "select notices_custom_list_value from notices_custom_lists where notices_custom_list_lib='" . addslashes($param_perso_900[$i]['a']) . "' and notices_custom_champ={$perso->idchamp}";
                    $resultat = pmb_mysql_query($requete);
                    if (pmb_mysql_num_rows($resultat)) {
                        $value = pmb_mysql_result($resultat, 0, 0);
                    } else {
                        $requete = "select max(notices_custom_list_value*1) from notices_custom_lists where notices_custom_champ={$perso->idchamp}";
                        $resultat = pmb_mysql_query($requete);
                        $max = @pmb_mysql_result($resultat, 0, 0);
                        $n = $max + 1;
                        $requete = "insert into notices_custom_lists (notices_custom_champ,notices_custom_list_value,notices_custom_list_lib) values({$perso->idchamp},{$n},'" . addslashes($param_perso_900[$i]['a']) . "')";
                        pmb_mysql_query($requete);
                        $value = $n;
                    }
                    $p_perso->values[$perso->idchamp][] = $value;
                } else {
                    $p_perso->values[$perso->idchamp][] = $param_perso_900[$i]['a'];
                }
            }
        }
    }
}
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:32,代码来源:func_customfields.inc.php


示例5: get_primaldata

 function get_primaldata()
 {
     global $dbh;
     $requete = "SELECT * FROM sub_collections WHERE sub_coll_id='" . addslashes($this->id) . "' ";
     $result = pmb_mysql_query($requete, $dbh);
     if (pmb_mysql_num_rows($result)) {
         $obj = pmb_mysql_fetch_object($result);
         pmb_mysql_free_result($result);
         $this->get_primaldatafrom($obj);
     } else {
         // pas de sous-collection avec cette clé
         $this->id = 0;
         $this->name = '';
         $this->parent = '';
         $this->parent_libelle = '';
         $this->parent_isbd = '';
         $this->publisher = '';
         $this->publisher_libelle = '';
         $this->publisher_isbd = '';
         $this->display = '';
         $this->issn = '';
         $this->isbd_entry = '';
         $this->comment = '';
     }
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:25,代码来源:subcollection.class.php


示例6: build_tree_sections

 protected function build_tree_sections($id_parent, $depth = 0)
 {
     global $dbh;
     if ($this->parameters['max_depth'] == 0 || $depth < $this->parameters['max_depth']) {
         $items = $ids = $rows = array();
         $query = "select id_section,section_title from cms_sections where section_num_parent = " . $id_parent . " order by section_order asc";
         $result = pmb_mysql_query($query, $dbh);
         if (pmb_mysql_num_rows($result)) {
             while ($row = pmb_mysql_fetch_object($result)) {
                 $ids[] = $row->id_section;
                 $rows[] = $row;
             }
             $ids = $this->filter_datas("sections", $ids);
             foreach ($rows as $row) {
                 if (in_array($row->id_section, $ids)) {
                     $section = cms_provider::get_instance("section", $row->id_section);
                     $item = array('id' => $row->id_section, 'title' => $row->section_title, 'link' => $this->get_constructed_link("section", $row->id_section), 'details' => $section->format_datas(false, false));
                     $sub_query = "select count(id_section) from cms_sections where section_num_parent = " . $row->id_section;
                     $sub_result = pmb_mysql_query($sub_query, $dbh);
                     if (pmb_mysql_num_rows($result) && pmb_mysql_result($sub_result, 0, 0) > 0) {
                         $item['children'] = $this->build_tree_sections($row->id_section, $depth + 1);
                     }
                     $items[] = $item;
                 }
             }
         }
     }
     return $items;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:29,代码来源:cms_module_menu_datasource_menu_editorial.class.php


示例7: get_datas

 public function get_datas()
 {
     global $opac_url_base;
     global $opac_show_book_pics;
     global $opac_book_pics_url;
     $datas = parent::get_datas();
     $notices = $datas['records'];
     $query = "select notice_id,tit1,thumbnail_url,code from notices where notice_id in(" . implode(",", $notices) . ")";
     $result = pmb_mysql_query($query);
     $notices = array();
     if (pmb_mysql_num_rows($result)) {
         while ($row = pmb_mysql_fetch_object($result)) {
             if ($opac_show_book_pics == '1' && ($opac_book_pics_url || $row->thumbnail_url)) {
                 $code_chiffre = pmb_preg_replace('/-|\\.| /', '', $row->code);
                 $url_image = $opac_book_pics_url;
                 $url_image = $opac_url_base . "getimage.php?url_image=" . urlencode($url_image) . "&noticecode=!!noticecode!!&vigurl=" . urlencode($row->thumbnail_url);
                 if ($row->thumbnail_url) {
                     $url_vign = $row->thumbnail_url;
                 } else {
                     if ($code_chiffre) {
                         $url_vign = str_replace("!!noticecode!!", $code_chiffre, $url_image);
                     } else {
                         $url_vign = $opac_url_base . "images/vide.png";
                     }
                 }
             }
             $notices[] = array('title' => $row->tit1, 'link' => $opac_url_base . "?lvl=notice_display&id=" . $row->notice_id, 'vign' => $url_vign);
         }
     }
     return array('records' => $notices);
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:31,代码来源:cms_module_carousel_datasource_notices.class.php


示例8: list_author_notices

 function list_author_notices($author_id, $OPACUserId = -1)
 {
     global $dbh;
     global $msg;
     $result = array();
     $author_id += 0;
     if (!$author_id) {
         throw new Exception("Missing parameter: author_id");
     }
     $rqt_auteurs = "select author_id as aut from authors where author_see='{$author_id}' and author_id!=0 ";
     $rqt_auteurs .= "union select author_see as aut from authors where author_id='{$author_id}' and author_see!=0 ";
     $res_auteurs = pmb_mysql_query($rqt_auteurs, $dbh);
     $clause_auteurs = " in ('{$author_id}' ";
     while ($id_aut = pmb_mysql_fetch_object($res_auteurs)) {
         $clause_auteurs .= ", '" . $id_aut->aut . "' ";
         $rqt_auteursuite = "select author_id as aut from authors where author_see='{$id_aut->aut}' and author_id!=0 ";
         $res_auteursuite = pmb_mysql_query($rqt_auteursuite, $dbh);
         while ($id_autsuite = pmb_mysql_fetch_object($res_auteursuite)) {
             $clause_auteurs .= ", '" . $id_autsuite->aut . "' ";
         }
     }
     $clause_auteurs .= " ) ";
     $requete = "SELECT distinct notices.notice_id FROM notices, responsability ";
     $requete .= "where responsability_author {$clause_auteurs} and notice_id=responsability_notice ";
     $requete .= "ORDER BY index_serie,tnvol,index_sew";
     $res = pmb_mysql_query($requete, $dbh);
     if ($res) {
         while ($row = pmb_mysql_fetch_assoc($res)) {
             $result[] = $row["notice_id"];
         }
     }
     //Je filtre les notices en fonction des droits
     $result = $this->filter_tabl_notices($result);
     return $result;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:35,代码来源:pmbesAuthors.class.php


示例9: get_datas

 public function get_datas()
 {
     $selector = $this->get_selected_selector();
     if ($selector) {
         $return = array();
         if (count($selector->get_value()) > 0) {
             foreach ($selector->get_value() as $value) {
                 $return[] = $value;
             }
         }
         $return = $this->filter_datas("articles", $return);
         if (count($return)) {
             $query = "select id_article,if(article_start_date != '0000-00-00 00:00:00',article_start_date,article_creation_date) as publication_date from cms_articles where id_article in (" . implode(",", $return) . ")";
             if ($this->parameters["sort_by"] != "") {
                 $query .= " order by " . $this->parameters["sort_by"];
                 if ($this->parameters["sort_order"] != "") {
                     $query .= " " . $this->parameters["sort_order"];
                 }
             }
             $result = pmb_mysql_query($query);
             if (pmb_mysql_num_rows($result)) {
                 $return = array();
                 while ($row = pmb_mysql_fetch_object($result)) {
                     $return[] = $row->id_article;
                 }
             }
         }
         return $return;
     }
     return false;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:31,代码来源:cms_module_common_datasource_articles.class.php


示例10: show_orinot

function show_orinot($dbh)
{
    global $msg;
    global $charset;
    print "<table>\n\t<tr>\n\t\t<th>{$msg['orinot_nom']}</th>\n\t\t<th>{$msg['orinot_pays']}</th>\n\t\t<th>{$msg['orinot_diffusable']}</th>\n\t</tr>";
    // affichage du tableau des statuts
    $requete = "SELECT orinot_id, orinot_nom, orinot_pays, orinot_diffusion FROM origine_notice ORDER BY orinot_nom ";
    $res = pmb_mysql_query($requete, $dbh);
    $nbr = pmb_mysql_num_rows($res);
    $parity = 1;
    for ($i = 0; $i < $nbr; $i++) {
        $row = pmb_mysql_fetch_object($res);
        if ($parity % 2) {
            $pair_impair = "even";
        } else {
            $pair_impair = "odd";
        }
        $parity += 1;
        $tr_javascript = " onmouseover=\"this.className='surbrillance'\" onmouseout=\"this.className='{$pair_impair}'\" onmousedown=\"document.location='./admin.php?categ=notices&sub=orinot&action=modif&id={$row->orinot_id}';\" ";
        print pmb_bidi("<tr class='{$pair_impair}' {$tr_javascript} style='cursor: pointer'><td>" . htmlentities($row->orinot_nom, ENT_QUOTES, $charset) . "</td><td>" . htmlentities($row->orinot_pays, ENT_QUOTES, $charset) . "</td>");
        if ($row->orinot_diffusion) {
            print "<td>{$msg['orinot_diffusable_oui']}</td>";
        } else {
            print "<td>{$msg['orinot_diffusable_non']}</td>";
        }
        print "</tr>";
    }
    print "</table>\n\t\t<input class='bouton' type='button' value=' {$msg['orinot_ajout']} ' onClick=\"document.location='./admin.php?categ=notices&sub=orinot&action=add'\" />";
}
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:29,代码来源:origine_notice.inc.php


示例11: update_avis

function update_avis($id)
{
    global $dbh, $desc, $sujet, $msg, $charset;
    header('Content-Type: text/html;charset=' . $charset);
    $req = "update avis set sujet='" . $sujet . "', commentaire='" . $desc . "' where id_avis='" . $id . "'";
    pmb_mysql_query($req, $dbh);
    $requete = "select avis.note, avis.sujet, avis.commentaire, avis.id_avis, DATE_FORMAT(avis.dateAjout,'" . $msg[format_date] . "') as ladate, ";
    $requete .= "empr_login, empr_nom, empr_prenom, ";
    $requete .= "niveau_biblio, niveau_biblio, valide, notice_id ";
    $requete .= "from avis ";
    $requete .= "left join empr on empr.id_empr=avis.num_empr ";
    $requete .= "left join notices on notices.notice_id=avis.num_notice ";
    $requete .= "where id_avis='" . $id . "'";
    $requete .= "order by index_serie, tnvol, index_sew ,dateAjout desc ";
    $res = pmb_mysql_query($requete, $dbh);
    while ($loc = pmb_mysql_fetch_object($res)) {
        $display = "\n\t\t\t<div class='left'>\n\t\t\t\t<input type='checkbox' name='valid_id_avis[]' id='valid_id_avis[]' value='{$loc->id_avis}' onClick=\"stop_evenement(event);\" />";
        if (!$loc->valide) {
            $display .= "<font color='#CC0000'>" . $msg[gestion_avis_note] . " <span >" . htmlentities($loc->note, ENT_QUOTES, $charset) . " <b>" . htmlentities($loc->sujet, ENT_QUOTES, $charset) . "</b></span></font>";
        } else {
            $display .= "<font color='#00BB00'>" . $msg[gestion_avis_note] . " <span >" . htmlentities($loc->note, ENT_QUOTES, $charset) . " <b>" . htmlentities($loc->sujet, ENT_QUOTES, $charset) . "</b></span></font>";
        }
        if ($charset != "utf-8") {
            $loc->commentaire = cp1252Toiso88591($loc->commentaire);
        }
        $display .= ", " . htmlentities($loc->ladate, ENT_QUOTES, $charset) . " " . htmlentities($loc->empr_prenom . " " . $loc->empr_nom, ENT_QUOTES, $charset) . "\n\t\t\t</div>\n\t\t\t<div class='row'>" . do_bbcode($loc->commentaire) . "\t</div>\n\t\t";
    }
    print $display;
}
开发者ID:hogsim,项目名称:PMB,代码行数:29,代码来源:avis_ajax.inc.php


示例12: fetch_data

 function fetch_data()
 {
     global $dbh;
     $this->selected_list = array();
     $req = "SELECT * FROM opac_filters where opac_filter_view_num=" . $this->id_vue . " and  opac_filter_path='" . $this->path . "' ";
     $myQuery = pmb_mysql_query($req, $dbh);
     if (pmb_mysql_num_rows($myQuery)) {
         $r = pmb_mysql_fetch_object($myQuery);
         $param = unserialize($r->opac_filter_param);
         $this->selected_list = $param["selected"];
     }
     $myQuery = pmb_mysql_query("SELECT * FROM docs_location order by location_libelle ", $dbh);
     $this->liste_item = array();
     $link = "";
     $i = 0;
     if (pmb_mysql_num_rows($myQuery)) {
         while ($r = pmb_mysql_fetch_object($myQuery)) {
             $this->liste_item[$i] = new stdClass();
             $this->liste_item[$i]->id = $r->idlocation;
             $this->liste_item[$i]->name = $r->location_libelle;
             if (in_array($r->idlocation, $this->selected_list)) {
                 $this->liste_item[$i]->selected = 1;
             } else {
                 $this->liste_item[$i]->selected = 0;
             }
             $i++;
         }
     }
     return true;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:30,代码来源:nav_sections.class.php


示例13: get_value

 public function get_value()
 {
     global $dbh;
     if ($this->parameters['sub_selector']) {
         $sub_selector = new $this->parameters['sub_selector']($this->get_sub_selector_id($this->parameters['sub_selector']));
         $values = $sub_selector->get_value();
         if (!is_array($values)) {
             if ($values != "") {
                 $values = array($values);
             } else {
                 $values = array();
             }
         }
         if (count($values)) {
             $tagslist = array();
             switch ($this->parameters['sub_selector']) {
                 case "cms_module_item_selector_item_generic":
                     $query = "select id_tag from docwatch_tags left join docwatch_items_tags on num_tag=id_tag where num_item in (" . implode(",", $values) . ")";
                     $result = pmb_mysql_query($query, $dbh);
                     if ($result) {
                         while ($row = pmb_mysql_fetch_object($result)) {
                             $tagslist[] = $row->id_tag;
                         }
                     }
                     return $tagslist;
                     break;
                 case "cms_module_common_selector_env_var":
                     return $values;
                     break;
             }
         }
     }
     return array();
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:34,代码来源:cms_module_itemslist_selector_itemstags.class.php


示例14: get_value

 public function get_value()
 {
     if (!$this->value) {
         $parent = new cms_module_common_selector_sections($this->get_sub_selector_id("cms_module_common_selector_sections"));
         $cp = new cms_module_common_selector_type_section_filter($this->get_sub_selector_id("cms_module_common_selector_type_section_filter"));
         $parents = $parent->get_value();
         $field = $cp->get_value();
         $var = new cms_module_common_selector_env_var($this->get_sub_selector_id("cms_module_common_selector_env_var"));
         $this->value = array();
         if (is_array($parents) && count($parents)) {
             $query = "select id_section from cms_sections where section_num_parent in (" . implode(",", $parents) . ")";
             $result = pmb_mysql_query($query);
             $fields = new cms_editorial_parametres_perso($field['type']);
             if (pmb_mysql_num_rows($result)) {
                 while ($row = pmb_mysql_fetch_object($result)) {
                     $fields->get_values($row->id_section);
                     if (in_array($var->get_value(), $fields->values[$field['field']])) {
                         $this->value[] = $row->id_section;
                     }
                 }
             }
         }
     }
     return $this->value;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:25,代码来源:cms_module_common_selector_sections_by_parent_and_cp.class.php


示例15: parametres_perso

 function parametres_perso($prefix)
 {
     global $_custom_prefixe_;
     $this->prefix = $prefix;
     $this->base_url = $base_url;
     $_custom_prefixe_ = $prefix;
     //Lecture des champs
     $this->no_special_fields = 0;
     $this->t_fields = array();
     $requete = "select idchamp, name, titre, type, datatype, obligatoire, options, multiple, export, search, opac_sort from " . $this->prefix . "_custom order by ordre";
     $resultat = pmb_mysql_query($requete);
     if (pmb_mysql_num_rows($resultat) == 0) {
         $this->no_special_fields = 1;
     } else {
         while ($r = pmb_mysql_fetch_object($resultat)) {
             $this->t_fields[$r->idchamp]["DATATYPE"] = $r->datatype;
             $this->t_fields[$r->idchamp]["NAME"] = $r->name;
             $this->t_fields[$r->idchamp]["TITRE"] = $r->titre;
             $this->t_fields[$r->idchamp]["TYPE"] = $r->type;
             $this->t_fields[$r->idchamp]["OPTIONS"] = $r->options;
             $this->t_fields[$r->idchamp]["MANDATORY"] = $r->obligatoire;
             $this->t_fields[$r->idchamp]["OPAC_SHOW"] = $r->multiple;
             $this->t_fields[$r->idchamp]["EXPORT"] = $r->export;
             $this->t_fields[$r->idchamp]["SEARCH"] = $r->search;
             $this->t_fields[$r->idchamp]["OPAC_SORT"] = $r->opac_sort;
         }
     }
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:28,代码来源:parametres_perso.class.php


示例16: do_selector_bul_section

function do_selector_bul_section($section_id, $location_id)
{
    global $dbh;
    global $charset;
    global $deflt_section;
    global $deflt_location;
    if (!$section_id) {
        $section_id = $deflt_section;
    }
    if (!$location_id) {
        $location_id = $deflt_location;
    }
    $rqtloc = "SELECT idlocation FROM docs_location order by location_libelle";
    $resloc = pmb_mysql_query($rqtloc, $dbh);
    while ($loc = pmb_mysql_fetch_object($resloc)) {
        $requete = "SELECT idsection, section_libelle FROM docs_section, docsloc_section where idsection=num_section and num_location='{$loc->idlocation}' order by section_libelle";
        $result = pmb_mysql_query($requete, $dbh);
        $nbr_lignes = pmb_mysql_num_rows($result);
        if ($nbr_lignes) {
            if ($loc->idlocation == $location_id) {
                $selector .= "<div id=\"docloc_section" . $loc->idlocation . "\" style=\"display:block\">";
            } else {
                $selector .= "<div id=\"docloc_section" . $loc->idlocation . "\" style=\"display:none\">";
            }
            $selector .= "<select name='f_ex_section" . $loc->idlocation . "' id='f_ex_section" . $loc->idlocation . "'>";
            while ($line = pmb_mysql_fetch_row($result)) {
                $selector .= "<option value='{$line['0']}'";
                $line[0] == $section_id ? $selector .= ' SELECTED>' : ($selector .= '>');
                $selector .= htmlentities($line[1], ENT_QUOTES, $charset) . '</option>';
            }
            $selector .= '</select></div>';
        }
    }
    return $selector;
}
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:35,代码来源:pointage_exemplarise.php


示例17: load

 function load()
 {
     global $dbh;
     $q = "select * from suggestions left join explnum_doc_sugg on num_suggestion=id_suggestion where id_suggestion = '" . $this->id_suggestion . "' ";
     $r = pmb_mysql_query($q, $dbh);
     $obj = pmb_mysql_fetch_object($r);
     $this->titre = $obj->titre;
     $this->editeur = $obj->editeur;
     $this->auteur = $obj->auteur;
     $this->code = $obj->code;
     $this->prix = $obj->prix;
     $this->nb = $obj->nb;
     $this->commentaires = $obj->commentaires;
     $this->commentaires_gestion = $obj->commentaires_gestion;
     $this->date_creation = $obj->date_creation;
     $this->date_decision = $obj->date_decision;
     $this->statut = $obj->statut;
     $this->num_produit = $obj->num_produit;
     $this->num_entite = $obj->num_entite;
     $this->num_rubrique = $obj->num_rubrique;
     $this->num_fournisseur = $obj->num_fournisseur;
     $this->num_notice = $obj->num_notice;
     $this->index_suggestion = $obj->index_suggestion;
     $this->url_suggestion = $obj->url_suggestion;
     $this->num_categ = $obj->num_categ;
     $this->sugg_location = $obj->sugg_location;
     $this->date_publi = $obj->date_publication;
     $this->sugg_src = $obj->sugg_source;
     $this->sugg_explnum = $obj->num_explnum_doc;
     $this->sugg_noti_unimarc = $obj->notice_unimarc;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:31,代码来源:suggestions.class.php


示例18: get_datas

 public function get_datas()
 {
     global $dbh;
     $return = array();
     $selector = $this->get_selected_selector();
     if ($selector) {
         $value = $selector->get_value();
         if ($value['publisher'] != 0) {
             $query = "select notice_id from notices where ed1_id = " . $value['publisher'] . ' and notice_id != ' . $value['record'];
             $result = pmb_mysql_query($query, $dbh);
             if (pmb_mysql_num_rows($result) > 0) {
                 $return["title"] = "Du même éditeur";
                 $records = array();
                 while ($row = pmb_mysql_fetch_object($result)) {
                     $records[] = $row->notice_id;
                 }
             }
             $return['records'] = $this->filter_datas("notices", $records);
             if ($this->parameters['nb_max_elements'] > 0) {
                 $return['records'] = array_slice($return['records'], 0, $this->parameters['nb_max_elements']);
             }
         }
         return $return;
     }
     return false;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:26,代码来源:cms_module_recordslist_datasource_records_publisher.class.php


示例19: search_other_function_filters

function search_other_function_filters()
{
    global $code_langue_restrict;
    global $charset, $msg, $marc_liste_langues;
    if (!$marc_liste_langues) {
        $marc_liste_langues = new marc_list('lang');
    }
    $r = "<select name='code_langue_restrict'>";
    $r .= "<option value=''>" . $msg[all_languages] . "</option>";
    $requete = "select distinct code_langue from notices_langues where code_langue is not null and code_langue!='' order by ordre_langue";
    $resultat = pmb_mysql_query($requete);
    // on met les balises <option> dans un tableau, indexé par le nom traduit de la langue
    $t = array();
    while ($res = pmb_mysql_fetch_object($resultat)) {
        if ($marc_liste_langues->table[$res->code_langue]) {
            $s = "<option value='" . htmlentities($res->code_langue, ENT_QUOTES, $charset) . "' ";
            if ($res->code_langue == $code_langue_restrict) {
                $s .= "selected";
            }
            $s .= ">" . $marc_liste_langues->table[$res->code_langue];
            $s .= "</option>";
            $t[$marc_liste_langues->table[$res->code_langue]] = $s;
        }
    }
    // tri le tableau selon les clés (ici les noms des langues, pas les codes)
    ksort($t);
    // recopie des balises triées dans la liste <select>
    foreach ($t as $k => $v) {
        $r .= $v;
    }
    $r .= "</select>";
    return $r;
}
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:33,代码来源:simple_search_add_language.inc.php


示例20: get_datas

 public function get_datas()
 {
     //on commence par récupérer l'identifiant retourné par le sélecteur...
     $selector = $this->get_selected_selector();
     if ($selector) {
         $section_id = $selector->get_value();
         $section_ids = $this->filter_datas("sections", array($section_id));
         if ($section_ids[0]) {
             $sections = array();
             $section_id = $section_ids[0];
             $datas = array();
             $i = 0;
             do {
                 $i++;
                 $query = "select id_section,section_num_parent from cms_sections where id_section = " . $section_id;
                 $result = pmb_mysql_query($query);
                 if (pmb_mysql_num_rows($result)) {
                     $row = pmb_mysql_fetch_object($result);
                     $section_id = $row->section_num_parent;
                     $datas[] = $row->id_section;
                 } else {
                     break;
                 }
                 //en théorie on sort toujours, mais comme c'est un pays formidable, on lock à 100 itérations...
             } while ($row->section_num_parent != 0 || $i > 100);
             return array_reverse($datas);
         }
     }
     return false;
 }
开发者ID:noble82,项目名称:proyectos-ULS,代码行数:30,代码来源:cms_module_breadcrumb_datasource_sections.class.php



注:本文中的pmb_mysql_fetch_object函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP pmb_mysql_fetch_row函数代码示例发布时间:2022-05-15
下一篇:
PHP pmb_mysql_fetch_assoc函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap