projects
/
php-utility-classes.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add appendComment() methods so we can add comments in an easy fashion
[php-utility-classes.git]
/
include
/
cbsm
/
util
/
document.php-class
diff --git
a/include/cbsm/util/document.php-class
b/include/cbsm/util/document.php-class
index 58637850153d708b5015f58f128f0df484be1dec..8f6c6cff7916bbf3a4de2682ed1a2fcd61a48720 100755
(executable)
--- a/
include/cbsm/util/document.php-class
+++ b/
include/cbsm/util/document.php-class
@@
-94,6
+94,10
@@
class ExtendedDocument extends DOMDocument {
// appends a DOMDocument::createTextNode() as a child of this document (see there for params)
// returns the new child
//
// appends a DOMDocument::createTextNode() as a child of this document (see there for params)
// returns the new child
//
+ // function appendComment($comment_data)
+ // appends a DOMDocument::createComment() as a child of this document (see there for params)
+ // returns the new child
+ //
// function appendHTMLMarkup($htmldata, [$parentNode])
// appends a representation of the HTML data as children of the given parent node, by default this document
// NO return value!
// function appendHTMLMarkup($htmldata, [$parentNode])
// appends a representation of the HTML data as children of the given parent node, by default this document
// NO return value!
@@
-216,6
+220,9
@@
class ExtendedDocument extends DOMDocument {
function appendText($text) {
return $this->appendChild($this->createTextNode($text));
}
function appendText($text) {
return $this->appendChild($this->createTextNode($text));
}
+ function appendComment($comment_data) {
+ return $this->appendChild($this->createComment($comment_data));
+ }
function appendJSElement($jsdata) {
$this->appendChild($this->createElementJS($jsdata));
}
function appendJSElement($jsdata) {
$this->appendChild($this->createElementJS($jsdata));
}
@@
-423,6
+430,10
@@
class ExtendedElement extends DOMElement {
// appends a DOMDocument::createTextNode() as a child of this element (see there for params)
// returns the new child
//
// appends a DOMDocument::createTextNode() as a child of this element (see there for params)
// returns the new child
//
+ // function appendComment($comment_data)
+ // appends a DOMDocument::createComment() as a child of this element (see there for params)
+ // returns the new child
+ //
// function appendHTMLMarkup($htmldata)
// appends a representation of the HTML data as children of this element
// NO return value!
// function appendHTMLMarkup($htmldata)
// appends a representation of the HTML data as children of this element
// NO return value!
@@
-487,6
+498,9
@@
class ExtendedElement extends DOMElement {
function appendText($text) {
return $this->appendChild($this->ownerDocument->createTextNode($text));
}
function appendText($text) {
return $this->appendChild($this->ownerDocument->createTextNode($text));
}
+ function appendComment($comment_data) {
+ return $this->appendChild($this->ownerDocument->createComment($comment_data));
+ }
function appendHTMLMarkup($htmldata) {
$this->ownerDocument->appendHTMLMarkup($htmldata, $this);
}
function appendHTMLMarkup($htmldata) {
$this->ownerDocument->appendHTMLMarkup($htmldata, $this);
}
@@
-566,6
+580,10
@@
class ExtendedDocumentFragment extends DOMDocumentFragment {
// appends a DOMDocument::createTextNode() as a child of this fragment (see there for params)
// returns the new child
//
// appends a DOMDocument::createTextNode() as a child of this fragment (see there for params)
// returns the new child
//
+ // function appendComment($comment_data)
+ // appends a DOMDocument::createComment() as a child of this fragment (see there for params)
+ // returns the new child
+ //
// function appendHTMLMarkup($htmldata)
// appends a representation of the HTML data as children of this fragment
// NO return value!
// function appendHTMLMarkup($htmldata)
// appends a representation of the HTML data as children of this fragment
// NO return value!
@@
-630,6
+648,9
@@
class ExtendedDocumentFragment extends DOMDocumentFragment {
function appendText($text) {
return $this->appendChild($this->ownerDocument->createTextNode($text));
}
function appendText($text) {
return $this->appendChild($this->ownerDocument->createTextNode($text));
}
+ function appendComment($comment_data) {
+ return $this->appendChild($this->ownerDocument->createComment($comment_data));
+ }
function appendHTMLMarkup($htmldata) {
$this->ownerDocument->appendHTMLMarkup($htmldata, $this);
}
function appendHTMLMarkup($htmldata) {
$this->ownerDocument->appendHTMLMarkup($htmldata, $this);
}