Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 18
  1. #1
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    Regardless of the situation, in any circumstances, ever, invoking create_element() on a DomDocument object for the DOM/XML module (http://www.php.net/domxml) returns null.

    I think it's a bug as I've updated an existing submission: http://bugs.php.net/bug.php?id=18119 . But, any thoughts on a workaround?
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  2.  

  3. #2
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    My solution was to stop beating php_domxml.dll with a stick and don't use it as an extension at all. I am now using PHP 5.1.0RC2 with the built-in DOM library (http://www.php.net/dom) and it's working happily. I just hope it ends up being backwards-compatible with PHP 4.3.10.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  4. #3
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times
    I don't know about php, but when you use document.createElement() in other dom models, the method returns a new, empty element obect, but does not append it to the document (or parent element). you have to later append it with element.appendChild().

  5. #4
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    PHP is the case like that too, but the element wasn't even being created.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  6. #5
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times
    Does your code look like this?
    Code:
    <?php
    $doc = domxml_new_doc("1.0");
    $root = $doc->create_element("root");
    $doc->append_child($root);
    ?>

  7. #6
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    It did, until I switched to the DOM methods instead of the domxml methods.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  8. #7
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times

  9. #8
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times
    Oh, I see...

  10. #9
    Senior Member Brak's Avatar
    Join Date
    Apr 2003
    Location
    San Francisco, CA
    Posts
    3,413
    Member #
    1217
    Liked
    2 times
    I think DOM/XML has serious issues...

    I tried last night to use it for a bit, and ended up an hour later switching to just creating strings. It wouldn't recognize ANY DOM functions - even though php_domxml.dll was activated, and phpinfo() indidcated all XML features activated and working.

    'tis a shame that it doesn't work that easily =/
    Kyle Neath: Rockstar extraordinare
    The blog | The poetry site | The Spore site

  11. #10
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    I had high hopes for it too. What a shame it ended up being a piece of garbage. The DOM module is so much better. It was easier to write the authoring part of my script in PHP than the reading part of the resulting XML in C#.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!


Page 1 of 2 1 2 LastLast

Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 11:43 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com