Welcome Guest, Not a member yet? Register   Sign In
Xml Help
#1

[eluser]Gerep[/eluser]
Hi guys,

I have the following xml files
<br />
estados.xml
Code:
<estados>
    <id>1</id>
    <nome>São Paulo</nome>
    <sigla>SP</sigla>

    <id>2</id>
    <nome>Minas Gerais</nome>
    <sigla>MG</sigla>
    ...
</estados>
cidades.xml
Code:
<cidades>
    <id>1</id>
    <id_estado>1</id_estado>
    <nome>Franca</nome>

    <id>2</id>
    <id_estado>2</id_estado>
    <nome>Cássia</nome>
    ...
</cidades>

I need to create two combobox to show my users the state and city, the city will be loaded based on the state selection and it need to be done via XML, my client won't use any database.

Thanks in advance and sorry for any typos :lol:
#2

[eluser]Atharva[/eluser]
You can use simplexml_load _file or simplexml_load_string functions




Theme © iAndrew 2016 - Forum software by © MyBB