当前位置: 首页>>代码示例>>PHP>>正文


PHP MySQLiConnectionFactory类代码示例

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


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

示例1: __construct

 public function __construct($id = null, $conType = 'readonly')
 {
     $this->conn = MySQLiConnectionFactory::getCon($conType);
     if ($id != null || is_numeric($id)) {
         $this->id = $id;
     }
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:7,代码来源:Manager.php

示例2: __construct

 function __construct()
 {
     $this->conn = MySQLiConnectionFactory::getCon('write');
     if ($this->conn === false) {
         exit("ABORT: Image upload aborted: Unable to establish connection to database");
     }
 }
开发者ID:brodypainter,项目名称:Symbiota,代码行数:7,代码来源:ImageProcessor.php

示例3: __construct

 function __construct($id)
 {
     $this->conn = MySQLiConnectionFactory::getCon("write");
     if (is_numeric($id)) {
         $this->clid = $id;
     }
 }
开发者ID:Symbiota,项目名称:Symbiota,代码行数:7,代码来源:InventoryDynSqlManager.php

示例4: __construct

 public function __construct()
 {
     $this->con = MySQLiConnectionFactory::getCon("readonly");
     //Default settings
     $this->taxAuthId = 1;
     //0 = do not resolve taxonomy (no thesaurus); 1 = default taxonomy; > 1 = other taxonomies
 }
开发者ID:brodypainter,项目名称:Symbiota,代码行数:7,代码来源:TaxonProfileManager.php

示例5: __construct

 function __construct()
 {
     set_time_limit(2000);
     $this->conn = MySQLiConnectionFactory::getCon("write");
     $this->setUploadTargetPath();
     $this->targetArr = array('url', 'originalUrl', 'scientificName', 'tid', 'photographer', 'photographerUid', 'caption', 'locality', 'sourceUrl', 'anatomy', 'notes', 'owner', 'copyright', 'sortSequence', 'institutionCode', 'collectionCode', 'catalogNumber', 'occid');
 }
开发者ID:Symbiota,项目名称:Symbiota,代码行数:7,代码来源:ImageImport.php

示例6: __construct

 function __construct()
 {
     $this->conn = MySQLiConnectionFactory::getCon("write");
     $this->setUploadTargetPath();
     set_time_limit(3000);
     ini_set("max_input_time", 120);
     ini_set('auto_detect_line_endings', true);
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:8,代码来源:TaxaUpload.php

示例7: __construct

 public function __construct($con = null)
 {
     if ($con) {
         //Inherits connection from another class
         $this->conn = $con;
     } else {
         $this->conn = MySQLiConnectionFactory::getCon("write");
     }
 }
开发者ID:Symbiota,项目名称:Symbiota,代码行数:9,代码来源:UuidFactory.php

示例8: editMetaData

 public function editMetaData()
 {
     $setSql = "";
     $con = MySQLiConnectionFactory::getCon("write");
     $sql = 'UPDATE omsurveys SET ' . 'projectname = ' . ($_POST['projectname'] ? '"' . $this->cleanInStr(trim($_POST['projectname'])) . '"' : 'NULL') . ', ' . 'managers = ' . ($_POST['managers'] ? '"' . $this->cleanInStr(trim($_POST['managers'])) . '"' : 'NULL') . ', ' . 'locality = ' . ($_POST['locality'] ? '"' . $this->cleanInStr(trim($_POST['locality'])) . '"' : 'NULL') . ', ' . 'notes = ' . ($_POST['notes'] ? '"' . $this->cleanInStr(trim($_POST['notes'])) . '"' : 'NULL') . ', ' . 'latcentroid = ' . ($_POST['latcentroid'] ? $this->cleanInStr($_POST['latcentroid']) : 'NULL') . ', ' . 'longcentroid = ' . ($_POST['longcentroid'] ? $this->cleanInStr($_POST['longcentroid']) : 'NULL') . ', ' . 'ispublic = ' . ($_POST['ispublic'] ? 1 : 0) . ' ' . 'WHERE (surveyid = ' . $this->surveyId . ')';
     //echo $sql;
     $con->query($sql);
     $con->close();
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:9,代码来源:SurveyManager.php

示例9: __construct

 public function __construct()
 {
     global $defaultLang;
     $this->con = MySQLiConnectionFactory::getCon("readonly");
     //Default settings
     $this->taxAuthId = 1;
     //0 = do not resolve taxonomy (no thesaurus); 1 = default taxonomy; > 1 = other taxonomies
     //$this->projName = "Arizona";
     $this->language = $defaultLang;
 }
开发者ID:urban011,项目名称:ut-prc-symbiota,代码行数:10,代码来源:TaxonProfileManager.php

示例10: __construct

 public function __construct($conn = null)
 {
     if ($conn) {
         $this->conn = $conn;
         $this->isShareConn = true;
     } else {
         $this->conn = MySQLiConnectionFactory::getCon("write");
     }
     $this->occFieldArr = array('catalognumber', 'othercatalognumbers', 'occurrenceid', 'family', 'scientificname', 'sciname', 'tidinterpreted', 'scientificnameauthorship', 'identifiedby', 'dateidentified', 'identificationreferences', 'identificationremarks', 'taxonremarks', 'identificationqualifier', 'typestatus', 'recordedby', 'recordnumber', 'associatedcollectors', 'eventdate', 'year', 'month', 'day', 'startdayofyear', 'enddayofyear', 'verbatimeventdate', 'habitat', 'substrate', 'fieldnumber', 'occurrenceremarks', 'associatedtaxa', 'verbatimattributes', 'dynamicproperties', 'reproductivecondition', 'cultivationstatus', 'establishmentmeans', 'lifestage', 'sex', 'individualcount', 'samplingprotocol', 'preparations', 'country', 'stateprovince', 'county', 'municipality', 'locality', 'localitysecurity', 'localitysecurityreason', 'decimallatitude', 'decimallongitude', 'geodeticdatum', 'coordinateuncertaintyinmeters', 'footprintwkt', 'locationremarks', 'verbatimcoordinates', 'georeferencedby', 'georeferenceprotocol', 'georeferencesources', 'georeferenceverificationstatus', 'georeferenceremarks', 'minimumelevationinmeters', 'maximumelevationinmeters', 'verbatimelevation', 'disposition', 'language', 'duplicatequantity', 'genericcolumn1', 'genericcolumn2', 'labelproject', 'observeruid', 'basisofrecord', 'ownerinstitutioncode', 'datelastmodified', 'processingstatus', 'recordenteredby', 'dateentered');
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:10,代码来源:OccurrenceEditorManager.php

示例11: __construct

 public function __construct()
 {
     global $serverRoot, $userRights, $isAdmin;
     //ini_set('memory_limit','512M');
     set_time_limit(500);
     //Ensure that PHP DOMDocument class is installed
     if (!class_exists('DOMDocument')) {
         exit('FATAL ERROR: PHP DOMDocument class is not installed, please contact your server admin');
     }
     $this->conn = MySQLiConnectionFactory::getCon('readonly');
     $this->ts = time();
     $this->condAllowArr = array('country', 'stateprovince', 'county', 'recordedby', 'family', 'sciname', 'processingstatus', 'ocr');
     $this->coreFieldArr = array('id' => '', 'accessURI' => 'http://rs.tdwg.org/ac/terms/accessURI', 'providerManagedID' => 'http://rs.tdwg.org/ac/terms/providerManagedID', 'title' => 'http://purl.org/dc/terms/title', 'comments' => 'http://rs.tdwg.org/ac/terms/comments', 'Owner' => 'http://ns.adobe.com/xap/1.0/rights/Owner', 'rights' => 'http://purl.org/dc/terms/rights', 'UsageTerms' => 'http://ns.adobe.com/xap/1.0/rights/UsageTerms', 'WebStatement' => 'http://ns.adobe.com/xap/1.0/rights/WebStatement', 'MetadataDate' => 'http://ns.adobe.com/xap/1.0/MetadataDate', 'associatedSpecimenReference' => 'http://rs.tdwg.org/ac/terms/associatedSpecimenReference', 'type' => 'http://purl.org/dc/terms/type', 'subtype' => 'http://rs.tdwg.org/ac/terms/subtype', 'format' => 'http://purl.org/dc/terms/format', 'metadataLanguage' => 'http://rs.tdwg.org/ac/terms/metadataLanguage');
     $this->stubFieldArr = array('coreid' => '', 'institutionCode' => 'http://rs.tdwg.org/dwc/terms/institutionCode', 'collectionCode' => 'http://rs.tdwg.org/dwc/terms/collectionCode', 'occurrenceID' => 'http://rs.tdwg.org/dwc/terms/occurrenceID', 'catalogNumber' => 'http://rs.tdwg.org/dwc/terms/catalogNumber', 'otherCatalogNumbers' => 'http://rs.tdwg.org/dwc/terms/otherCatalogNumbers', 'family' => 'http://rs.tdwg.org/dwc/terms/family', 'scientificName' => 'http://rs.tdwg.org/dwc/terms/scientificName', 'scientificNameAuthorship' => 'http://rs.tdwg.org/dwc/terms/scientificNameAuthorship', 'genus' => 'http://rs.tdwg.org/dwc/terms/genus', 'specificEpithet' => 'http://rs.tdwg.org/dwc/terms/specificEpithet', 'taxonRank' => 'http://rs.tdwg.org/dwc/terms/taxonRank', 'infraspecificEpithet' => 'http://rs.tdwg.org/dwc/terms/infraspecificEpithet', 'identifiedBy' => 'http://rs.tdwg.org/dwc/terms/identifiedBy', 'dateIdentified' => 'http://rs.tdwg.org/dwc/terms/dateIdentified', 'identificationReferences' => 'http://rs.tdwg.org/dwc/terms/identificationReferences', 'identificationRemarks' => 'http://rs.tdwg.org/dwc/terms/identificationRemarks', 'taxonRemarks' => 'http://rs.tdwg.org/dwc/terms/taxonRemarks', 'identificationQualifier' => 'http://rs.tdwg.org/dwc/terms/identificationQualifier', 'typeStatus' => 'http://rs.tdwg.org/dwc/terms/typeStatus', 'recordedBy' => 'http://rs.tdwg.org/dwc/terms/recordedBy', 'recordNumber' => 'http://rs.tdwg.org/dwc/terms/recordNumber', 'eventDate' => 'http://rs.tdwg.org/dwc/terms/eventDate', 'year' => 'http://rs.tdwg.org/dwc/terms/year', 'month' => 'http://rs.tdwg.org/dwc/terms/month', 'day' => 'http://rs.tdwg.org/dwc/terms/day', 'startDayOfYear' => 'http://rs.tdwg.org/dwc/terms/startDayOfYear', 'endDayOfYear' => 'http://rs.tdwg.org/dwc/terms/endDayOfYear', 'verbatimEventDate' => 'http://rs.tdwg.org/dwc/terms/verbatimEventDate', 'habitat' => 'http://rs.tdwg.org/dwc/terms/habitat', 'substrate' => '', 'fieldNumber' => 'http://rs.tdwg.org/dwc/terms/fieldNumber', 'occurrenceRemarks' => 'http://rs.tdwg.org/dwc/terms/occurrenceRemarks', 'informationWithheld' => 'http://rs.tdwg.org/dwc/terms/informationWithheld', 'dynamicProperties' => 'http://rs.tdwg.org/dwc/terms/dynamicProperties', 'associatedTaxa' => 'http://rs.tdwg.org/dwc/terms/associatedTaxa', 'reproductiveCondition' => 'http://rs.tdwg.org/dwc/terms/reproductiveCondition', 'establishmentMeans' => 'http://rs.tdwg.org/dwc/terms/establishmentMeans', 'lifeStage' => 'http://rs.tdwg.org/dwc/terms/lifeStage', 'sex' => 'http://rs.tdwg.org/dwc/terms/sex', 'individualCount' => 'http://rs.tdwg.org/dwc/terms/individualCount', 'samplingProtocol' => 'http://rs.tdwg.org/dwc/terms/samplingProtocol', 'preparations' => 'http://rs.tdwg.org/dwc/terms/preparations', 'country' => 'http://rs.tdwg.org/dwc/terms/country', 'stateProvince' => 'http://rs.tdwg.org/dwc/terms/stateProvince', 'county' => 'http://rs.tdwg.org/dwc/terms/county', 'municipality' => 'http://rs.tdwg.org/dwc/terms/municipality', 'locality' => 'http://rs.tdwg.org/dwc/terms/locality', 'decimalLatitude' => 'http://rs.tdwg.org/dwc/terms/decimalLatitude', 'decimalLongitude' => 'http://rs.tdwg.org/dwc/terms/decimalLongitude', 'geodeticDatum' => 'http://rs.tdwg.org/dwc/terms/geodeticDatum', 'coordinateUncertaintyInMeters' => 'http://rs.tdwg.org/dwc/terms/coordinateUncertaintyInMeters', 'footprintWKT' => 'http://rs.tdwg.org/dwc/terms/footprintWKT', 'verbatimCoordinates' => 'http://rs.tdwg.org/dwc/terms/verbatimCoordinates', 'georeferencedBy' => 'http://rs.tdwg.org/dwc/terms/georeferencedBy', 'georeferenceProtocol' => 'http://rs.tdwg.org/dwc/terms/georeferenceProtocol', 'georeferenceSources' => 'http://rs.tdwg.org/dwc/terms/georeferenceSources', 'georeferenceVerificationStatus' => 'http://rs.tdwg.org/dwc/terms/georeferenceVerificationStatus', 'georeferenceRemarks' => 'http://rs.tdwg.org/dwc/terms/georeferenceRemarks', 'minimumElevationInMeters' => 'http://rs.tdwg.org/dwc/terms/minimumElevationInMeters', 'maximumElevationInMeters' => 'http://rs.tdwg.org/dwc/terms/maximumElevationInMeters', 'verbatimElevation' => 'http://rs.tdwg.org/dwc/terms/verbatimElevation', 'ocrOutput' => '', 'language' => 'http://purl.org/dc/terms/language', 'recordId' => 'http://portal.idigbio.org/terms/recordId');
     $this->securityArr = array('locality', 'minimumElevationInMeters', 'maximumElevationInMeters', 'verbatimElevation', 'decimalLatitude', 'decimalLongitude', 'geodeticDatum', 'coordinateUncertaintyInMeters', 'footprintWKT', 'verbatimCoordinates', 'georeferenceRemarks', 'georeferencedBy', 'georeferenceProtocol', 'georeferenceSources', 'georeferenceVerificationStatus', 'habitat', 'informationWithheld');
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:16,代码来源:DwcArchiverExpedition.php

示例12: __construct

 public function __construct()
 {
     global $userRights, $isAdmin, $charset;
     $this->conn = MySQLiConnectionFactory::getCon('readonly');
     //Set rare species variables
     $this->securityArr = array('locality', 'locationRemarks', 'minimumElevationInMeters', 'maximumElevationInMeters', 'verbatimElevation', 'decimalLatitude', 'decimalLongitude', 'geodeticDatum', 'coordinateUncertaintyInMeters', 'footprintWKT', 'verbatimCoordinates', 'georeferenceRemarks', 'georeferencedBy', 'georeferenceProtocol', 'georeferenceSources', 'georeferenceVerificationStatus', 'habitat');
     if ($isAdmin || array_key_exists("CollAdmin", $userRights) || array_key_exists("RareSppAdmin", $userRights) || array_key_exists("RareSppReadAll", $userRights)) {
         $this->redactLocalities = false;
     }
     if (array_key_exists('CollEditor', $userRights)) {
         $this->rareReaderArr = $userRights['CollEditor'];
     }
     if (array_key_exists('RareSppReader', $userRights)) {
         $this->rareReaderArr = array_unique(array_merge($this->rareReaderArr, $userRights['RareSppReader']));
     }
     //Character set
     $this->charSetSource = strtoupper($charset);
     $this->charSetOut = $this->charSetSource;
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:19,代码来源:OccurrenceDownload.php

示例13: __construct

 public function __construct()
 {
     //Ensure that PHP DOMDocument class is installed
     if (!class_exists('DOMDocument')) {
         exit('FATAL ERROR: PHP DOMDocument class is not installed, please contact your server admin');
     }
     $this->conn = MySQLiConnectionFactory::getCon('readonly');
     $this->ts = time();
     if (!$this->logFH && $this->verbose) {
         $logFile = $GLOBALS['SERVER_ROOT'] . (substr($GLOBALS['SERVER_ROOT'], -1) == '/' ? '' : '/') . "temp/logs/DWCA_" . date('Y-m-d') . ".log";
         $this->logFH = fopen($logFile, 'a');
     }
     //Character set
     $this->charSetSource = strtoupper($GLOBALS['CHARSET']);
     $this->charSetOut = $this->charSetSource;
     $this->condAllowArr = array('catalognumber', 'othercatalognumbers', 'occurrenceid', 'family', 'sciname', 'country', 'stateprovince', 'county', 'municipality', 'recordedby', 'recordnumber', 'eventdate', 'decimallatitude', 'decimallongitude', 'minimumelevationinmeters', 'maximumelevationinmeters', 'datelastmodified', 'dateentered');
     $this->securityArr = array('eventDate', 'month', 'day', 'startDayOfYear', 'endDayOfYear', 'verbatimEventDate', 'recordNumber', 'locality', 'locationRemarks', 'minimumElevationInMeters', 'maximumElevationInMeters', 'verbatimElevation', 'decimalLatitude', 'decimalLongitude', 'geodeticDatum', 'coordinateUncertaintyInMeters', 'footprintWKT', 'verbatimCoordinates', 'georeferenceRemarks', 'georeferencedBy', 'georeferenceProtocol', 'georeferenceSources', 'georeferenceVerificationStatus', 'habitat', 'informationWithheld');
     //ini_set('memory_limit','512M');
     set_time_limit(500);
 }
开发者ID:brodypainter,项目名称:Symbiota,代码行数:20,代码来源:DwcArchiverOccurrence.php

示例14: __construct

 public function __construct()
 {
     $this->conn = MySQLiConnectionFactory::getCon("write");
     $this->imageRootPath = $GLOBALS["imageRootPath"];
     if (substr($this->imageRootPath, -1) != "/") {
         $this->imageRootPath .= "/";
     }
     $this->imageRootUrl = $GLOBALS["imageRootUrl"];
     if (substr($this->imageRootUrl, -1) != "/") {
         $this->imageRootUrl .= "/";
     }
     if (array_key_exists('imgTnWidth', $GLOBALS)) {
         $this->tnPixWidth = $GLOBALS['imgTnWidth'];
     }
     if (array_key_exists('imgWebWidth', $GLOBALS)) {
         $this->webPixWidth = $GLOBALS['imgWebWidth'];
     }
     if (array_key_exists('imgFileSizeLimit', $GLOBALS)) {
         $this->webFileSizeLimit = $GLOBALS['imgFileSizeLimit'];
     }
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:21,代码来源:GlossaryManager.php

示例15: __construct

 public function __construct($collId = 0)
 {
     $this->collId = $collId;
     $this->conn = MySQLiConnectionFactory::getCon("write");
     $sql = 'SELECT collid, institutioncode, collectioncode, collectionname, colltype FROM omcollections ';
     if ($collId && is_numeric($collId)) {
         $sql .= 'WHERE (collid = ' . $collId . ')';
     } else {
         $sql .= 'WHERE (colltype = "General Observations")';
     }
     $rs = $this->conn->query($sql);
     if ($r = $rs->fetch_object()) {
         $this->collMap['collid'] = $r->collid;
         $this->collMap['institutioncode'] = $r->institutioncode;
         $this->collMap['collectioncode'] = $r->collectioncode;
         $this->collMap['collectionname'] = $this->cleanOutStr($r->collectionname);
         $this->collMap['colltype'] = $r->colltype;
         if (!$this->collId) {
             $this->collId = $r->collid;
         }
     }
     $rs->close();
 }
开发者ID:jphilip124,项目名称:Symbiota,代码行数:23,代码来源:ObservationSubmitManager.php


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