corillo181 Posted November 5, 2009 Share Posted November 5, 2009 Hey guys, I am new to messing around with xml and I want to know if this is possible. I am working on a website where they do not have access to any database and they are not willing to move to another server. What I want to know is how can I use xml to set up a news database.. Well I know how to use xml for that what I want to do is how can I use IDs or Dates to get information as I would on a database? Link to comment https://forums.phpfreaks.com/topic/180453-help-with-simplexml/ Share on other sites More sharing options...
lemmin Posted November 5, 2009 Share Posted November 5, 2009 Can't you tier it just like you would in a database? <table> <id> <field1>value</field1> <field2>value</field2> </id> </table> Link to comment https://forums.phpfreaks.com/topic/180453-help-with-simplexml/#findComment-951998 Share on other sites More sharing options...
corillo181 Posted November 5, 2009 Author Share Posted November 5, 2009 Yeah but lets say I am adding additional articles.. <news> <article> <date>...</date> <story></story> <headline></headline> </article> <article> <date>...</date> <story></story> <headline></headline> </article> </news> lets say I will keep adding more articles how do I get the latest ones. Link to comment https://forums.phpfreaks.com/topic/180453-help-with-simplexml/#findComment-952009 Share on other sites More sharing options...
lemmin Posted November 5, 2009 Share Posted November 5, 2009 Can't you just name the tag the id of the article instead of "article?" Or what about setting an attribute of it? <article id="1"> Link to comment https://forums.phpfreaks.com/topic/180453-help-with-simplexml/#findComment-952012 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.