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


PHP DOMDocument::__construct方法代碼示例

本文整理匯總了PHP中DOMDocument::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP DOMDocument::__construct方法的具體用法?PHP DOMDocument::__construct怎麽用?PHP DOMDocument::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在DOMDocument的用法示例。


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

示例1: __construct

 public function __construct()
 {
     parent::__construct('1.0', 'UTF-8');
     $this->formatOutput = true;
     $this->rootElement = $this->createElement('testsuites');
     $this->appendChild($this->rootElement);
 }
開發者ID:ryanaslett,項目名稱:junit-xml,代碼行數:7,代碼來源:Document.php

示例2: __construct

 public function __construct($text)
 {
     parent::__construct();
     $this->preserveWhiteSpace = false;
     $this->LoadXML($text);
     $this->formatOutput = true;
 }
開發者ID:csev,項目名稱:tsugi-php,代碼行數:7,代碼來源:TsugiDOM.php

示例3: __construct

 public function __construct()
 {
     parent::__construct('1.0', 'UTF-8');
     $this->preserveWhiteSpace = false;
     $this->formatOutput = true;
     return $this;
 }
開發者ID:floatla,項目名稱:ModLayer-Docs,代碼行數:7,代碼來源:xmldom.php

示例4: __construct

	public function __construct($data, $version = null, $encoding = null)
	{
		parent::__construct($version, $encoding);
		$this->registerNodeClass('DOMDocument', 'JS_Extractor');
		$this->registerNodeClass('DOMElement', 'JS_Extractor_Element');
		@$this->loadHTML($data);
	}
開發者ID:kevinreilly,項目名稱:mendelements.com,代碼行數:7,代碼來源:Extractor.php

示例5: __construct

 public function __construct($version = '1.0', $encoding = 'utf-8')
 {
     parent::__construct($version, $encoding);
     $this->registerNodeClass('DOMAttr', 'Libs\\DOM\\Attribute');
     $this->registerNodeClass('DOMDocument', 'Libs\\DOM\\Document');
     $this->registerNodeClass('DOMElement', 'Libs\\DOM\\Element');
 }
開發者ID:psychoticmeowAffliction,項目名稱:affliction,代碼行數:7,代碼來源:document.php

示例6: __construct

 /**
  * Constructor de la clase.
  *
  * @access public
  * @param  string  $xml  (la ruta del archivo XML)
  */
 public function __construct($xml = null)
 {
     parent::__construct('1.0', 'utf-8');
     if ($this->load($xml) === true) {
         $this->carga = true;
     }
 }
開發者ID:njmube,項目名稱:ConsultaCFDIService,代碼行數:13,代碼來源:LecturaXML.php

示例7: __construct

 /**
  * 構造函數
  * @param string $fileName xml文件名
  * @param bool $isSax 是否存儲成SimpleXMLElement對象
  */
 public function __construct($fileName = '', $isSax = true, $version = '1.0', $encoding = 'utf-8')
 {
     parent::__construct($version, $encoding);
     $this->fileName = $fileName;
     $this->isSax = $isSax;
     $this->fileName && $this->loadFromFile();
 }
開發者ID:a4m,項目名稱:go1den-express,代碼行數:12,代碼來源:Xml.class.php

示例8: __construct

 /**
  * @param string $version
  * @param string $encoding
  */
 public function __construct($version = '1.0', $encoding = 'UTF-8')
 {
     parent::__construct($version, $encoding);
     foreach ($this->_classes as $superClass => $className) {
         $this->registerNodeClass($superClass, __NAMESPACE__ . $className);
     }
 }
開發者ID:fluentdom,項目名稱:fluentdom,代碼行數:11,代碼來源:Document.php

示例9: __construct

 /**
  * Creates the <salesinvoice> element and adds it to the property
  * salesInvoicesElement
  * 
  * @access public
  */
 public function __construct()
 {
     parent::__construct();
     // Make the main wrap element
     $this->salesInvoicesElement = $this->createElement('salesinvoices');
     $this->appendChild($this->salesInvoicesElement);
 }
開發者ID:japaveh,項目名稱:twinfield,代碼行數:13,代碼來源:InvoicesDocument.php

示例10: __construct

 public function __construct($version = null, $encoding = null)
 {
     parent::__construct($version, $encoding);
     $this->registerNodeClass('DOMText', 'DOMWrap\\Text');
     $this->registerNodeClass('DOMElement', 'DOMWrap\\Element');
     $this->registerNodeClass('DOMComment', 'DOMWrap\\Comment');
 }
開發者ID:vladshut,項目名稱:php-dom-wrapper,代碼行數:7,代碼來源:Document.php

示例11: __construct

 public function __construct($version = '1.0', $encoding = 'utf-8')
 {
     parent::__construct($version, $encoding);
     $this->preserveWhitespace = false;
     $this->formatOutput = false;
     $this->_errorLog = array();
 }
開發者ID:pointybeard,項目名稱:forking-server-framework,代碼行數:7,代碼來源:class.xmldocument.php

示例12: __construct

 public function __construct()
 {
     parent::__construct('1.0', 'utf-8');
     $this->registerNodeClass('DOMElement', 'app\\modules\\yiipass\\services\\KeepassXGroup');
     $db = $this->createElement('database');
     $this->appendChild($db);
     $this->db = $db;
 }
開發者ID:jepster,項目名稱:yiipass,代碼行數:8,代碼來源:KeepassXDbDoc.php

示例13: uniqid

 function __construct()
 {
     $this->sessionid = uniqid();
     parent::__construct('1.0', 'UTF-8');
     $this->formatOutput = true;
     //$this->standalone = false;
     #$this->validateOnParse = true;
 }
開發者ID:metaregistrar,項目名稱:php-epp-client,代碼行數:8,代碼來源:eppRequest.php

示例14: __construct

 /**
  * Creates a new response xml document to iterate
  * through its resource properties
  * @param string $xml_response_string
  */
 public function __construct($xml_response_string)
 {
     parent::__construct(self::XML_VERSION, self::XML_ENCODING);
     $this->loadXML($xml_response_string);
     if ($this->success() === true) {
         $this->__resourceNodeList = $this->getElementsByTagName('resourceDescriptor');
     }
 }
開發者ID:philippjenni,項目名稱:icinga-web,代碼行數:13,代碼來源:JasperResponseXmlDoc.class.php

示例15: __construct

 /**
  * constructor
  * set up an Atom_Element instance
  *
  * @param string $tagName
  * @example 
  * $feed = new Atom_Element('feed') 
  * is similar to
  * $feed = new DOMDocument;
  * $feed->appendChild(new DOMElement('feed'))
  * @access public 
  */
 public function __construct($tagName='')
 {
     parent::__construct();
     if($tagName!='' && $tagName!=null)
     {
         $this->appendChild(new DOMElement($tagName));
     }
 }
開發者ID:krispouille,項目名稱:xml_atom,代碼行數:20,代碼來源:Element.php


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