You are here: Howto: PHP4 Dom XML to PHP5 XML ? « PHP Programming Language « IT news, forums, messages
Howto: PHP4 Dom XML to PHP5 XML ?

Posted by dk_sz on 08/11/05 16:21

Can anyone point me to a guide or something for conversion?
I tryed
http://alexandre.alapetite.net/doc-alex/domxml-php4-php5/index.en.html
but it doesn't work (not all parts anyway) - and as I can't find a
working IDE/debugger combination I can't currently figure out why.


I need to translate following code:


PHP4
$eir_dom = domxml_open_mem($eir_padfile_content);
$eir_root_node = $eir_dom->document_element(); // = root element
PHP5
$eir_dom = new DOMDocument;
$eir_dom->loadXml($eir_padfile_content);
// need equalant of: document_element();

PHP4
.... $nodes = $cur_root_node->child_nodes();
.... if ($test_node->node_name() == $next_node_name_to_find) {
PHP5
// need equalant of: child_nodes(); node_name()

PHP4
.... if ($node_child->node_type() == XML_TEXT_NODE) {
$node_child->set_content($new_content);
break;
}
PHP5
// need equalant of: set_content, node_type()



best regards
Thomas Schulz

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация