DOMDocument->__construct()
DOMDocument->__construct() — 新しい DOMDocument オブジェクトを作成する
説明
class DOMDocument {__construct ( [string version [, string encoding]] )
} 新しい
DOMDocument
オブジェクトを作成します。
パラメータ
- version
-
XML 宣言の一部である、ドキュメントのバージョン番号。
- encoding
-
XML 宣言の一部である、ドキュメントのエンコーディング。
例
例 486. 新しい DOMDocument を作成する
<?php
$dom = new DOMDocument('1.0', 'iso-8859-1');
echo $dom->saveXML(); /* <?xml version="1.0" encoding="iso-8859-1"?> */
?>
参考
DOMImplementation->createDocument() |
Weblioに収録されているすべての辞書からDOMDocument->__construct()を検索する場合は、下記のリンクをクリックしてください。

- DOMDocument->__construct()のページへのリンク