mmtalon Posted January 16, 2007 Share Posted January 16, 2007 Can PHP 4.3.x support this document object code?[code]alert("bodyNode.firstChild.nodeName = " + bodyNode.firstChild.nodeName);[/code] Quote Link to comment Share on other sites More sharing options...
fenway Posted January 16, 2007 Share Posted January 16, 2007 I'm not sure why you think this has anything to do with PHP... Quote Link to comment Share on other sites More sharing options...
mmtalon Posted January 17, 2007 Author Share Posted January 17, 2007 First, I don't know if the code example is deprecated because of a later version of the document object model (DOM). Or, perhaps, the code is designed for a later version of DOM, where PHP 4.3.x won't support the newer version of DOM. I was hoping that someone would recognize the code as being to old or not new enough. I thought that the PHP server is what translate the javascript to the client computer and that the PHP server would ultimately be the problem. Do correct me if I am wrong on how javascript reaches the client computer. Quote Link to comment Share on other sites More sharing options...
mmtalon Posted January 17, 2007 Author Share Posted January 17, 2007 What I meant to say was too old or too new. Quote Link to comment Share on other sites More sharing options...
mainewoods Posted January 22, 2007 Share Posted January 22, 2007 [quote]PHP 4.3.x won't support the newer version of DOM[/quote]NO php supports the DOM. php returns html source code as text, and the DOM is not even created until the browser parses the html. The DOM is accessable from javascript - not php. Your DOM support problem is a browser type/version problem.[code]alert("bodyNode.firstChild.nodeName = " + bodyNode.firstChild.nodeName);[/code]--I have read that the 'firstChild' object is not supported by ie6 and older ie. ie7 is supposed to have support. Your problem is an ie DOM compatability issue. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.