當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Connexion類代碼示例

本文整理匯總了PHP中Connexion的典型用法代碼示例。如果您正苦於以下問題:PHP Connexion類的具體用法?PHP Connexion怎麽用?PHP Connexion使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了Connexion類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: update

 public function update()
 {
     $connexion = new Connexion();
     $sql = "";
     $sql = "UPDATE \"libertribes\".\"CASE\" set coord = '" . $this->coord . "', occupee_par = '" . $this->occupee_par . "', occupant_id = '" . $this->occupant_id . "', nom_terrain = '" . $this->nom_terrain . "' ";
     $sql .= "WHERE id = '" . $this->id . "'";
     return $connexion->Requete($sql);
 }
開發者ID:domiboo,項目名稱:libertribes_fromneosys,代碼行數:8,代碼來源:class_caza.php

示例2: delete

 public function delete($type, $id)
 {
     $db = new Connexion();
     $class = $type;
     $table = strtolower($class);
     $prefixe = substr($table, 0, 3) . "_";
     $query = "DELETE FROM " . $table;
     $query .= " WHERE " . $prefixe . "id = " . $id;
     $request = $db->query($query);
     $db = null;
 }
開發者ID:athomix,項目名稱:ecommerce,代碼行數:11,代碼來源:classModel.php

示例3: validationFormulaireSuppressionServices

function validationFormulaireSuppressionServices()
{
    $id = $_POST['idServicesSuppr'];
    $requete = 'Delete From services Where id = ' . $id . '';
    Connexion::exec($requete);
    echo '<META http-equiv="refresh" content="0; URL=?page=services&supprOk">';
}
開發者ID:lelenaic,項目名稱:Monitoring-CLF,代碼行數:7,代碼來源:fonctions_validationFormulaireAjoutServices.php

示例4: getInstance

 public static function getInstance()
 {
     if (is_null(self::$_instance)) {
         self::$_instance = new Connexion();
     }
     return self::$_instance;
 }
開發者ID:bosoy83,項目名稱:keywords-analyzer,代碼行數:7,代碼來源:class.connexion.php

示例5: menuUtilisateur

function menuUtilisateur($menuParent_id = null)
{
    $utilisateur = $_SESSION['utilisateur'];
    $query = 'select * ' . 'from menu m, utilisateurtype_menu um ' . 'where um.utilisateurtype_id=' . $utilisateur['utilisateurtype_id'] . ' and m.id=um.menu_id';
    if (is_null($menuParent_id)) {
        $query .= ' and m.menuparent_id is null';
    } else {
        $query .= ' and m.menuparent_id=' . $menuParent_id;
    }
    $query .= ' order by um.ordre';
    $menus = Connexion::table($query);
    $html = '';
    foreach ($menus as $menu) {
        if ($menu['route'] == '') {
            $url = '#';
        } else {
            $url = '.?route=' . $menu['route'];
        }
        $enfants = menuUtilisateur($menu['id']);
        if ($enfants != '') {
            $class = ' class="treeview"';
        } else {
            $class = '';
        }
        $html .= '<li' . $class . '>
                <a href="' . $url . '">
                <i class="fa ' . $menu['icon'] . '"></i> <span>' . $menu['label'] . '</span>
                </a>';
        if ($enfants != '') {
            $html .= '<ul class="treeview-menu">' . $enfants . '</ul>';
        }
        $html .= '</li>';
    }
    return $html;
}
開發者ID:lelenaic,項目名稱:erp-PPE2,代碼行數:35,代碼來源:menu.php

示例6: getAll

 /**
  * Fonction de récupération de l'ensemble des pages du site. 
  * 
  * Permet de récupérer l'ensemble des pages du site.
  * @return results correspond à l'ensemble des pages trouvées.
  */
 public static function getAll($niveau)
 {
     $querry = 'SELECT * FROM page  WHERE droit<=:niveau';
     Connexion::executeQuerry($querry, array(':niveau' => array($niveau, PDO::PARAM_INT)));
     $results = Connexion::getResults();
     return $results;
 }
開發者ID:hlefe,項目名稱:sosprema,代碼行數:13,代碼來源:PageGateway.php

示例7: getAll

 /**
  * Fonction de récupéreration l'ensemble des adresse.
  * 
  * Récupère l'ensemble des adresse de la table, cette fonction n'est pas utilisée pour le moment.
  * @return result retourne le résultat de la recherche de l'adresse.
  */
 public static function getAll()
 {
     $querry = 'SELECT * FROM adresse';
     Connexion::executeQuerry($querry);
     $results = Connexion::getResults();
     return $results;
 }
開發者ID:hlefe,項目名稱:sosprema,代碼行數:13,代碼來源:AdresseGateway.php

示例8: execute

 public function execute()
 {
     $db = Connexion::getConnexion();
     $statement = $db->prepare("DELETE FROM shows WHERE id = ?");
     $statement->bindValue(1, $_POST["id"], PDO::PARAM_INT);
     $statement->execute();
 }
開發者ID:phil714,項目名稱:mel,代碼行數:7,代碼來源:DeleteDigestAction.php

示例9: valid_route

function valid_route()
{
    //Récupération du formulaire.
    $nom = $_POST['nom'];
    $prenom = $_POST['prenom'];
    $adresse = $_POST['adresse'];
    $codePostal = $_POST['codePostal'];
    $ville = $_POST['ville'];
    $mail = $_POST['mail'];
    $numTel = $_POST['numTel'];
    if ($_SESSION['utilisateur']['utilisateurtype_id'] == 1) {
        $organisation = $_POST['organisation'];
        $organisationRecupId = Connexion::queryFirst("SELECT id FROM organisation WHERE libelle='" . $organisation . "'");
        $organisationId = $organisationRecupId['id'];
    } else {
        $organisationId = $_SESSION['utilisateur']['entreprise_id'];
    }
    $organisation = $_POST['organisation'];
    $organisationId = Connexion::queryFirst("SELECT id FROM organisation where libelle='" . $organisation . "'");
    //vérification si aucune zone de texte est restée vide pour envoi à la BDD.
    if ($nom != "" and $prenom != "" and $adresse != "" and $codePostal != "" and $ville != "" and $mail != "" and $numTel != "") {
        $query = 'INSERT INTO client (nom, prenom, adresse, codePostal, ville, entreprise_id, mail, numTelephone)' . "VALUES ('" . $nom . "', '" . $prenom . "', '" . $adresse . "', '" . $codePostal . "', '" . $ville . "','.{$organisationId['id']}.', '" . $mail . "', '" . $numTel . "')";
        Connexion::exec($query);
        include ROOT . 'AdminLTE/alerte.php';
    } else {
        $tableAjout = [$nom, $prenom, $adresse, $codePostal, $ville, $mail, $numTel, $organisation];
        formulaire($tableAjout, true);
    }
}
開發者ID:lelenaic,項目名稱:erp-PPE2,代碼行數:29,代碼來源:ajoutIndex.php

示例10: produit_route

function produit_route()
{
    $produits = Connexion::table('SELECT libelleProduit,reference,fournisseur.nom,poids,produit.id
                            FROM produit, fournisseur
                            WHERE fournisseur.id=produit.fournisseur_id');
    include ROOT . 'AdminLTE/kernel/produit/liste.php';
}
開發者ID:lelenaic,項目名稱:erp-PPE2,代碼行數:7,代碼來源:liste.php

示例11: liste_route

function liste_route()
{
    $employe = Connexion::table('select * from employe order by id');
    $poste = Connexion::table('select * from poste');
    $entreprise = Connexion::table('select * from organisation');
    include ROOT . 'AdminLTE/grh/employe/liste.php';
}
開發者ID:lelenaic,項目名稱:erp-PPE2,代碼行數:7,代碼來源:employe.php

示例12: getAdwordsData

 public function getAdwordsData()
 {
     $targetingIdeaService = $this->user->GetService('TargetingIdeaService', ADWORDS_VERSION);
     $selector = new TargetingIdeaSelector();
     $selector->requestType = 'STATS';
     $selector->ideaType = 'KEYWORD';
     $selector->requestedAttributeTypes = array('SEARCH_VOLUME', 'COMPETITION');
     $selector->paging = new Paging(0, AdWordsConstants::RECOMMENDED_PAGE_SIZE);
     $selector->localeCode = 'fr_FR';
     $selector->currencyCode = 'EUR';
     $language = new Language();
     $language->id = '1002';
     $selector->searchParameters[] = new LanguageSearchParameter($language);
     $relatedToQuerySearchParameter = new RelatedToQuerySearchParameter();
     $relatedToQuerySearchParameter->queries = $this->keyword['keyword'];
     $selector->searchParameters[] = $relatedToQuerySearchParameter;
     $page = $targetingIdeaService->get($selector);
     if (sizeof($page->entries) > 0) {
         $vol = $page->entries[0]->data[0]->value->value == 0 ? 5 : $page->entries[0]->data[0]->value->value;
         $comp = (double) round($page->entries[0]->data[1]->value->value, 2);
         Connexion::getInstance()->query("UPDATE keyword SET search = '" . $vol . "', competition = '" . round($comp, 2) . "' WHERE id_keyword = '" . $this->keyword['id_keyword'] . "' ");
     } else {
         Connexion::getInstance()->query("UPDATE keyword SET search = '5', competition = '0' WHERE id_keyword = '" . $this->keyword['id_keyword'] . "' ");
     }
 }
開發者ID:bosoy83,項目名稱:keywords-analyzer,代碼行數:25,代碼來源:class.adwords.php

示例13: __construct

 public function __construct($immatricule, $nom, $prenom, $zone)
 {
     $this->con = Connexion::connect();
     $this->immatricule = $immatricule;
     $this->nom = $nom;
     $this->prenom = $prenom;
     $this->zone = $zone;
 }
開發者ID:benzirab,項目名稱:SMT,代碼行數:8,代碼來源:BDE.php

示例14: __construct

 public function __construct($dbhost, $dbname, $user, $password)
 {
     $this->host = $dbhost;
     $this->dbname = $dbname;
     $this->user = $user;
     $this->password = $password;
     $this->bdd = Connexion::getConnexion($dbhost, $dbname, $user, $password);
 }
開發者ID:KevinAlberca,項目名稱:Sup_ORM,代碼行數:8,代碼來源:DatabaseChecker.php

示例15: connect

 function connect()
 {
     if (!$this->connected) {
         parent::__construct($this->connexion->getDns(), $this->connexion->getUserName(), $this->connexion->getPassWord(), $this->connexion->getOptions());
         $this->connected = true;
     }
     return $this;
 }
開發者ID:fzed51,項目名稱:OAD,代碼行數:8,代碼來源:AccessDB.php


注:本文中的Connexion類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。