I have XML that comes from the Paraná Business Association containing queries about a person's document.
Previously, they had a static "layout pattern", which made it easy to turn into an HTML table to display on my site. I could do the reading on foreachs, and it always worked. However, now the information that comes will always change according to the document consulted.
My idea is to refactor the class that reads this XML and converts it to HTML. But I have no idea to begin.
I would like something flexible, that I could customize the labels and their values (to format, for example, when it is date or values) and not depend on an X number of foreachs, since the sub-levels always change. / p>
XML:
link (I put it in the HTML for viewing)
The XMLs may be smaller, but I've taken a very extensive here to show more or less how they come. Today, I get the contents of "record-acsp-net" and display on the screen in table format through the code below:
As you can see, it's not the coolest thing in the world. Actually, this code above was not done by me, but I'm having to maintain it often just because of these problems.
In short: I have XML mentioned and would like to convert it into an HTML table, so you can flex your labels and values so you can format as you want. Is there anything ready already in this sense? Or a light of how can I do?