Implement dynamic XML
First built table: CREATE TABLE books (bookid int (4) NOT NULL auto_increment, bookname varchar (100) NOT NULL, bookauth varchar (50) NOT NULL, bookpublisher varchar (50) NOT NULL, bookpubdate datetime NOT NULL, bookurl varchar (50 NOT NULL, Key BookId (BookID), then. . . This section is the source code to XML from MySQL to XML: $ Connect_id = mysql_connect ("localhost", "root", ""); mysql_select_db ("bbs", $ connection_id); $ query = "SELECT * From books order by bookid "; $ r = mysql_query ($ query, $ connection_id); $ numberfields = mysql_num_fields ($ r); $ xmlfile =" XML Version = "1.0" encoding = "GB2312"?> n "; $ XMLFILE. = "