Commit Graph

382 Commits

Author SHA1 Message Date
Rob Richards
e1fa06393d MFB: fix underlying issue for bug #38438 2006-08-14 11:29:49 +00:00
Ilia Alshanetsky
a41723d0f4 MFB: Fixed bug #38438 (DOMNodeList->item(0) segfault on empty NodeList) 2006-08-13 15:03:19 +00:00
Antony Dovgal
dbe2092313 implement zend_unicode_to_string() and zend_string_to_unicode()
part #2 (of 2)
2006-08-08 16:59:11 +00:00
Antony Dovgal
f1a098cbdc fix types, add missing parentheses 2006-08-07 20:22:33 +00:00
Rob Richards
2008a88704 update tests
use binary strings for loadXML() method
2006-08-05 12:35:35 +00:00
Rob Richards
4c98426979 unicode changes 2006-08-05 12:33:34 +00:00
Rob Richards
f85e695409 add unicode support
update test
2006-08-04 18:11:27 +00:00
Christian Stocker
1f4cce3e0f MFB
improved code (after suggestion by helly)
2006-07-16 16:04:35 +00:00
Christian Stocker
812887cedb Added DOMNode::getNodePath() for getting an XPath for a node.
(MFB)
2006-07-16 15:05:32 +00:00
Hannes Magnusson
e18bb1ce3d Fix/add SKIPIF 2006-06-27 00:09:23 +00:00
Hannes Magnusson
d9f977e685 Add missing header include 2006-06-20 18:00:11 +00:00
Antony Dovgal
8fd8789c9a nuke unused variables and init variables when needed 2006-06-20 13:21:10 +00:00
Ilia Alshanetsky
b37a784265 MFB: Removed unused variables. 2006-06-13 20:20:03 +00:00
Antony Dovgal
0816690760 fix error messages in Unicode mode 2006-06-02 21:55:26 +00:00
Rob Richards
653007cea0 idness not valid for attribute declarations 2006-06-02 16:15:58 +00:00
Rob Richards
d178e8d3e4 add C14N() and C14NFile() methods to perform XML canonicalization
add test
2006-05-26 18:22:06 +00:00
Rob Richards
e88f13a86d add test 2006-05-22 17:05:38 +00:00
Rob Richards
43dfe5ec59 add test 2006-05-17 16:32:35 +00:00
Rob Richards
85e8f351d5 Fix bug #37456 (DOMElement->setAttribute() loops forever) 2006-05-17 16:32:04 +00:00
Rob Richards
a91a72f800 add test 2006-05-03 08:41:33 +00:00
Rob Richards
b1f52e79aa Fix bug #37277 (cloning Dom Documents or Nodes does not work)
Proper fix for bug #36859
2006-05-03 08:40:52 +00:00
Antony Dovgal
6a53a49c8b MF51: fix bug #36898 (__set() leaks in classes extending internal ones)
Added:
ZEND_API void zend_object_std_init(zend_object *object, zend_class_entry *ce TSRMLS_DC)
ZEND_API void zend_object_std_dtor(zend_object *object TSRMLS_DC)
2006-03-29 15:08:52 +00:00
Antony Dovgal
ae7fbe8132 MF51: fix #36859 (DOMElement crashes when calling __construct when clone'ing) 2006-03-26 00:23:37 +00:00
Rob Richards
7fc0756e55 MFB51: Fixed bug #36756 (DOMDocument::removeChild corrupts node)
add test
2006-03-18 11:46:13 +00:00
Dmitry Stogov
7c0e534157 Dropped zend.ze1_compatibility_mode 2006-03-16 10:33:23 +00:00
Rob Richards
206e50fc60 update dom iterator get key function for engine iterator changes
fix crashes using notations and entity decls
add test
2006-03-03 20:13:12 +00:00
Michael Wallner
92f97ce76a - MF51: fix crash in DOMImplementation::createDocumentType("name:") 2006-02-24 10:24:43 +00:00
Dmitry Stogov
0f1209ab3d Portable unicode string API:
- use the same type (int) for zval.value.usr.len and zval.value.str.len
  - use union "zstr" as char*/UChar* mixture instead of void*
  - Z_UNISTR() and Z_UNILEN() no longer check for Z_TYPE()
  - nuke int32_t from ZE (not finisned)
2006-02-21 20:12:43 +00:00
Dmitry Stogov
332e557ac2 Fixed start inex in iterator 2006-02-20 10:29:35 +00:00
Dmitry Stogov
09ca61c125 Made server wide switch for unicode on/off (according to PDM). 2006-02-13 10:23:59 +00:00
Rob Richards
e1e5c3f3b2 modify get_iterator call for engine change 2006-02-07 11:48:37 +00:00
Rob Richards
b8ded17f81 fix possible crash in textContent 2006-01-25 17:33:24 +00:00
Dmitry Stogov
227295a4f1 Unicode stuff is changed according to decision maden on PDM.
Now IS_BINRAY data type is removed and IS_STRING starts behave as IS_BINARY in unicode mode. IS_STRING is incompatible with IS_UNICODE, so ALL functions should be improved to support unicode mode.
2006-01-17 12:18:53 +00:00
foobar
251c5173fd bump year and license version 2006-01-01 13:10:10 +00:00
Antony Dovgal
9e23794cb8 MFB: fix typo 2005-12-18 21:17:42 +00:00
Marcus Boerger
5d60cbc498 - MFB Fix export 2005-12-17 15:44:44 +00:00
Antony Dovgal
67f9574b78 fix test
this linenumber may vary
2005-12-16 14:57:13 +00:00
foobar
a208d9a966 - Nuke php3 legacy 2005-12-06 02:28:26 +00:00
Rob Richards
8c8f92f45f add test 2005-11-23 03:10:45 +00:00
Rob Richards
406910e1e9 add registerNodeClass() method
- methods can now natively return user classes registered with document
2005-11-23 02:56:41 +00:00
Rob Richards
73e6869340 implement setIDAttributeXXX functionality 2005-11-23 02:52:56 +00:00
Rob Richards
8038df9ce2 Fixed bug #35342 (isset(DOMNodeList->length) returns false). 2005-11-23 00:55:34 +00:00
Dmitry Stogov
8bb39e7dba Allow recursive calls to __get/__set for different properties 2005-11-15 15:21:47 +00:00
Antony Dovgal
e658842761 fix #35197 (Destructor is not called) and similar issues in other extensions 2005-11-14 21:52:27 +00:00
Marcus Boerger
ff72c376c2 - MFB Fix tests expectations 2005-11-06 10:53:39 +00:00
Rasmus Lerdorf
f16fb8484d MFB - We don't need the simplexml requirement here anymore 2005-11-05 22:32:55 +00:00
Rob Richards
a953be4fff fix crash setting attr from foreign doc (throws exception)
add test
2005-10-27 23:49:38 +00:00
Ilia Alshanetsky
37015ffcfa MFB51: Fixed tests to work with ZTS builds 2005-10-20 19:22:55 +00:00
Dmitry Stogov
b45944a5b3 Fixed access to uninitialized value 2005-09-19 18:47:36 +00:00
Rob Richards
d1cf2c5ffe add save options parameter 2005-09-08 10:34:37 +00:00
Rob Richards
4509fb9d5d Fixed bug #34276 (setAttributeNS doesn't work with default namespace)
Add test
2005-08-28 16:22:03 +00:00
foobar
98ce7bf37b - Removed EOL from error message 2005-08-18 12:40:17 +00:00
Dmitry Stogov
3658f1fb7b Unicode support 2005-08-18 11:47:03 +00:00
Dmitry Stogov
d0944d74f4 Unicode support 2005-08-16 15:09:51 +00:00
Rob Richards
bbe63287e7 Fixed bug #34103 (line numbering not maintained in dom document) 2005-08-15 17:13:15 +00:00
Dmitry Stogov
0bdfac1169 Tests are fixed according to new var_dump()/pront_r() format (to pass in non-unicode mode) 2005-08-15 07:55:41 +00:00
Dmitry Stogov
96a24404ce Unicode support 2005-08-12 14:57:58 +00:00
Sebastian Bergmann
52b001cc05 ZTS fixes. 2005-08-12 14:08:28 +00:00
Dmitry Stogov
21c1109e0c Unicode support 2005-08-12 11:29:33 +00:00
Andrei Zmievski
264cec8be6 Unicode support. 2005-08-11 23:36:07 +00:00
foobar
23e671a51e - Bumber up year 2005-08-03 14:08:58 +00:00
Rob Richards
b27d49579a Allow NULL namespaceURI for getAttributeNodeNS 2005-07-07 10:36:08 +00:00
foobar
2967f6116f - Fixed bugs #33431, #33432 ("int" used instead of "long" in parameter parsing) 2005-06-26 22:34:26 +00:00
foobar
eccc955ed5 fix test 2005-06-23 10:57:52 +00:00
Dmitry Stogov
fd2d420919 Fixed test file according to latest debug_backtrace() fixes 2005-06-23 09:25:00 +00:00
Rob Richards
9ad129468a - Fix bug #33299 (php:function no longer handles returned dom objects)
- maybe fix #33431/33432
2005-06-22 19:56:30 +00:00
Dmitry Stogov
60328db583 Debug backtrace was fixed 2005-06-22 15:30:14 +00:00
Dmitry Stogov
f47c78487b Improved PHP extension loading mechanism with support for module dependencies and conflicts 2005-06-17 09:39:23 +00:00
foobar
a20383ba06 - Unify the "configure --help" texts 2005-05-29 23:17:16 +00:00
Rob Richards
022461d976 - correct fix for bug #33059
- fix issue in other methods
2005-05-20 15:01:38 +00:00
Ilia Alshanetsky
e117b6bad2 Fixed bug #33059 (crash when moving xml attribute set in dtd). 2005-05-19 13:47:21 +00:00
foobar
626253940e - Added PHP_INSTALL_HEADERS() macro
- Fixed several VPATH build issues
- Changed all awk calls to use $AWK
- Changed all mkdir calls to use "$php_shtool mkdir"
2005-05-07 02:51:53 +00:00
Rob Richards
6d2fd215e9 Fix bug #32930 (class extending DOMDocument doesn't clone properly) 2005-05-03 22:55:03 +00:00
foobar
39bcbfc306 - Made the libxml related stuff to error out if someone does --disable-all
or --disable-libxml. Better than silently just leave the ext out..
2005-04-27 13:12:55 +00:00
Ilia Alshanetsky
8b8940ba84 php_error() -> php_error_docref(). 2005-04-21 21:11:23 +00:00
Rob Richards
334d756ffa Fix bug #32755 Segfault in replaceChild() when DocumentFragment has no children
update test
2005-04-18 23:07:50 +00:00
Andrey Hristov
d9f5f1ee08 fix memory corruption on 64bit in imagefttext(),
domdocument::load() and domdocument::loadxml()
2005-04-10 21:37:17 +00:00
Rob Richards
5313e98b72 - Fixed bug #32615 (Segfault in replaceChild() using fragment when
previousSibling is NULL)
- add test
2005-04-08 15:58:24 +00:00
Rob Richards
9c3919c3a3 fix test 2005-04-08 12:18:57 +00:00
Rob Richards
8913ddc295 use new error handling when not throwing exceptions 2005-02-20 22:01:24 +00:00
Rob Richards
b1157ff8d9 Fragment must have associated document to append xml otherwise it is read-only 2005-02-18 11:57:24 +00:00
Rob Richards
e46e7309f8 Fixed bug #32011 (Fragments which replaced Nodes are not globaly useable) 2005-02-18 11:47:20 +00:00
foobar
67a965a7e0 No tabs here 2005-02-15 01:44:10 +00:00
Rob Richards
08592b38da Fixed bug #31878 (Segmentation fault using clone keyword on nodes) 2005-02-09 11:46:43 +00:00
Rob Richards
dd2f5ed142 Fixed bug #28817 (Var problem when extending domDocument). 2005-01-20 11:47:05 +00:00
Rob Richards
a3335dba69 revert fix for bug #28817 - fix is bad 2005-01-11 10:36:08 +00:00
Marcus Boerger
79687e9b7d - Fix dependency 2005-01-08 13:24:39 +00:00
Rob Richards
6bbb254ecc allow parser flags to be passed to xinclude() 2005-01-02 12:22:36 +00:00
Rob Richards
cb72e23c14 add optional parameter to pass libxml document load options 2004-12-05 12:02:35 +00:00
Rob Richards
28076f78ed add test 2004-12-04 11:40:10 +00:00
Rob Richards
25554b8118 Fixed bug #28817 (Var problem when extending domDocument). (Georg) 2004-12-04 11:39:34 +00:00
Antony Dovgal
ed5638bf77 fix tests 2004-12-02 16:33:36 +00:00
Rob Richards
b87d8cdfd0 prototype fixes (Jakub Vrána) 2004-11-18 19:54:30 +00:00
Rob Richards
7dced12c32 add DOMDocument xmlEncoding, xmlStandalone, xmlVersion (spec name changes)
add DOMText isElementContentWhitespace (spec name change)
 - old props/method kept for BC.
 - spec names changed when Level 3 went from Draft to Recommendation
nuke some unused code
2004-10-07 11:40:20 +00:00
Rob Richards
b0ffa2497b fix segfault in appendXML due to libxml bug 2004-10-07 10:00:39 +00:00
Rob Richards
5f630e1935 add evaluate() method to support all xpath expressions 2004-10-03 09:55:29 +00:00
Rob Richards
02fa5aa0dc remove cloning under ze1_compatibility_mode
- minor BC break but doesnt work right under compat mode anyways
2004-08-30 15:07:20 +00:00
Rob Richards
518145133f not experimental 2004-08-26 20:13:33 +00:00
Christian Stocker
b96ebb376f if $doc->recover = true; set error_reporting to (old | E_WARNING)
This way, you can't silence XML parse errors with the @ character
2004-08-25 08:27:07 +00:00
Christian Stocker
e99c375606 Added DomDocument->recover property for parsing not well-formed XML Documents. 2004-08-13 12:32:55 +00:00
Christian Stocker
786ffab310 fix test 2004-08-11 08:23:26 +00:00
Marcus Boerger
aae7a83df4 - Fixed Bug #29354 Exception constructor marked as both public and
protected
# If the constructor should be protected then it needs to be overwritten
# with a method that simply calls the parent, this function simply changes
# the visibility of the original function and makes that (public+protected)
2004-07-25 18:50:24 +00:00
Rob Richards
5c17925a7c add appendXML() to DOMFragment (chregu) 2004-07-18 13:47:44 +00:00
Rob Richards
8925d6573e MFB: add missing optional value param to createElementNS (chregu) 2004-07-18 13:16:15 +00:00
Wez Furlong
ed682e570a Implement extension load-order deps. 2004-07-18 12:03:51 +00:00
Rob Richards
7c7c353b1e Fixed bug #28771 (Segfault when using xslt and clone)
Add test case for bug #28721
2004-06-15 11:50:56 +00:00
Rob Richards
e73d498947 Fix bug #28721 (appendChild() and insertBefore() unset DOMText) 2004-06-13 10:12:47 +00:00
Rob Richards
5b0f34ae80 Fix bug #28584: DOMText::splitText() does not split text properly (benjcarson)
Prototype fixes
2004-05-31 12:50:28 +00:00
Zeev Suraski
7d04465b74 Fix prototypes 2004-05-31 12:27:49 +00:00
Zeev Suraski
e54165e406 No meaning for unsigned 2004-05-30 17:34:11 +00:00
Rob Richards
edae935c26 namespace/tagname validation fixes (Adam Trachtenberg)
added new test
2004-05-27 11:15:45 +00:00
Andrey Hristov
44de5a0e8e fixing the tests so to work with the new var_dump() (dumping private and
protected member variables)
2004-05-20 21:13:14 +00:00
Rob Richards
9e3956b313 constructors throw DOMException
add DOM_PHP_ERR DomException code
validate tagnames in constructors
use C style comments
update TODO
2004-05-16 10:30:16 +00:00
Ilia Alshanetsky
e81addb5ca C++ comments. 2004-04-29 12:59:26 +00:00
Rob Richards
7b1f927ef5 register_namespace changed to registerNamespace for consistency 2004-04-06 18:26:19 +00:00
Rob Richards
010c340f29 use new style constructors
fix return for nodelist item
2004-03-31 17:18:59 +00:00
Marcus Boerger
904dac52e2 DOM_RET_OBJ for return_value needs to be followed by return 2004-03-29 21:05:16 +00:00
Marcus Boerger
585af2418b Remove debug code 2004-03-29 20:54:46 +00:00
Marcus Boerger
4dc6fe7f62 Fix tests 2004-03-29 20:54:13 +00:00
Ilia Alshanetsky
0d0fffe98b Fixed compiler warnings. 2004-03-29 19:57:51 +00:00
Marcus Boerger
43d3d8a0a4 Fix class names 2004-03-29 19:31:29 +00:00
Stanislav Malyshev
5b0f6b1f34 Update for new read_property API 2004-03-21 18:28:38 +00:00
Marcus Boerger
979ef59b7c Rename hasMore() to valid() as discussed. (Part IV) 2004-03-08 21:15:39 +00:00
Rob Richards
4ce377064a Fix bug #27467: domDocument::load() called from class method crashes
the methods can be called statically only from within classes which
  are not extending DomDocument
2004-03-03 20:59:02 +00:00
Rob Richards
76ee5707f7 Fix bug #27436 dom_import_simplexml innaccurate
extensions register callbacks to export nodes
prevents segfault passing invalid objects to import functions
2004-03-01 12:09:24 +00:00
Rob Richards
081e773f86 add optional third parameter to support namespace in constructor 2004-02-22 13:05:49 +00:00
Rob Richards
7deeb0f96a always return domnodelist unless error 2004-02-18 22:42:30 +00:00
Rob Richards
4051591cfe correct implementation of prefix write property 2004-02-18 20:37:30 +00:00
Rob Richards
43eb077107 add dtor to cleanup iterator related data 2004-02-17 19:57:48 +00:00
Rob Richards
ec2ea131fb implement clone functionality to fix segfault
DomNode->clone() creates new doc proxy if document is cloned
remove printf from xpath
fix remaining invalid object state issues
2004-02-17 11:13:47 +00:00
Rob Richards
602c786aa9 issue warning if object is in invalid state when dealing with properties 2004-02-16 13:06:33 +00:00
Rob Richards
2a32e4328a switch to zend_parse_method_parameters for consistancy
insure object parameters are correct class types
convert zvals to correct type if needed for property writes
fix a few segfaults found while testing
2004-02-15 18:57:10 +00:00
Rob Richards
c3a57206cc allow certain methods to be called statically again:
domdocument (all load methods)
   domimplementation (all methods)
switch to zend_parse_method_parameters for consistancy
insure object parameters are correct class types
convert zvals to correct type if needed for property writes
fix a few segfaults found while testing
2004-02-15 17:07:34 +00:00
Rob Richards
c1418894dd switch to zend_parse_method_parameters for consistancy
insure object parameters are correct class types
convert zvals to correct type if needed for property writes
2004-02-15 14:05:17 +00:00
Rob Richards
a2e1844de9 start of dom update
switch to zend_parse_method_parameters for consistancy
insure object parameters are correct class types
convert zvals to correct type if needed for property writes
2004-02-15 10:54:37 +00:00
Zeev Suraski
30171a7590 zend_default_classes.h -> zend_exceptions.h 2004-02-12 10:43:27 +00:00
Ilia Alshanetsky
91f46b7880 Fixed compile warnings. 2004-02-04 14:15:16 +00:00
Zeev Suraski
8424be849f - Update with new destructor code 2004-02-04 11:14:47 +00:00
Rob Richards
b5e7a6dae0 update test 2004-01-22 22:12:21 +00:00
Rob Richards
7e619b7f5f update constructors so they cant be called statically 2004-01-22 21:16:05 +00:00
Rob Richards
a4815f7c8e Warn when empty string supplied to load methods (by Pierre-Alain)
Fix refcount on xpath iterators
xpath_query should return nodelist even when empty
2004-01-20 11:35:32 +00:00
Marcus Boerger
920358a0cc Fix warning (and possible problem) 2004-01-20 07:27:47 +00:00
Christian Stocker
6b70f9d1b3 Fix leaks in dom_xpath_query (create retval only if requiered) by Pierre-Alain 2004-01-19 21:08:29 +00:00
Christian Stocker
00af01bb94 fixes segfault, if file doesn't exist (by Pierre-Alain) 2004-01-19 20:54:40 +00:00
Christian Stocker
743a830102 - fix for bug #26947 Crash by using DomDocument::getElementById() 2004-01-18 12:56:23 +00:00
foobar
f4983c0d3f - Renamed all *php4* files to *php5*, changed all php4/PHP4 to php5/PHP5 2004-01-17 13:00:38 +00:00
Rob Richards
38f8ed0e0a fix getElementsByTagName and getElementsByTagNameNS - allow * 2004-01-13 14:13:21 +00:00
Rob Richards
394bf2ba5b XPath query returns nodelist object rather than array 2004-01-10 11:50:25 +00:00
foobar
ccfc46b0aa - Happy new year and PHP 5 for rest of the files too..
# Should the LICENSE and Zend/LICENSE dates be updated too?
2004-01-08 17:33:29 +00:00
Andi Gutmans
dbeb4158d2 - A belated happy holidays and PHP 5 2004-01-08 08:18:22 +00:00