I am working on a Google Map and have everything working the way I want. I just need a way to get data from a form to post into an XML file so I don't have to edit the XML everytime I want to update my list of locations for the map.
Here is the form: http://crappyfiles.com/maps/form.html
<form action="formproc.php" enctype="text/plain" onSubmit="POST">
<div align="center">
<table width="600">
<tr>
<td width="71">Name:</td>
<td width="161"><input type="text" name="name"></td>
<td width="352">Please enter name or description of Address </td>
</tr>
<tr>
<td>Address:</td>
<td><input type="text" name="address"></td>
<td>Please enter only Street address.</td>
</tr>
<tr>
<td>City:</td>
<td><input type="text" name="city"></td>
<td>Required</td>
</tr>
<tr>
<td>State:</td>
<td><input type="text" name="state"></td>
<td>Required</td>
</tr>
<tr>
<td>Zip:</td>
<td><input type="text" name="zip"></td>
<td>Please enter 4 Digit Zip code </td>
</tr>
<tr>
<td>Phone:</td>
<td><input type="text" name="phone"></td>
<td>Please enter phone # like (555) 555-5555 </td>
</tr>
<tr>
<td>Latitude:</td>
<td><input type="text" name="lat"></td>
<td>Enter Latitude like: 45.777658</td>
</tr>
<tr>
<td>Longitude:</td>
<td><input type="text" name="long"></td>
<td>Enter Longitude like: -073.729749</td>
</tr>
<tr>
<td>URL:</td>
<td><input type="text" name="url"></td>
<td>Enter Website as [url]www.website.com[/url] </td>
</tr>
<tr>
<td>Status</td>
<td><select name="status">
<option value="active">Active
<option value="disabled">Disabled
<option value="pending">Pending
</select></td>
<td>Please select one option </td>
</tr>
<tr>
<td><input type="submit" name="Submit" value="Submit"></td>
<td colspan="2"><input type="reset" name="Reset" value="Reset Form"></td>
</tr>
</table>
</div>
</form>
I figured I would have to have it post to a php script that will then parse the data, open the xml file and post the date to the xml file and close the xml file.
I don't have the php file created, that is where the problem lies. I need some help. I am not asking for the script to be written for me. I will attempt to do it myself. I would like some help finding similar scripts that do what I am asking.
Here is the XML file: http://crappyfiles.com/maps/addresses.xml
<?xml version="1.0" encoding="ISO-8859-1" ?>
<addresses>
<name street="1234 Main St" city="AnyTown" state="IA" zip="50226" phone="(555) 555-5555"
long="-073.729749" lat="45.777658" url="http://www.mysite.com" status="active">Firstname Lastname</name>
</addresses>
I don't know where to start with this, I don't know much about PHP and little to nothing about XML. Worst case scenario, I have to manually update the XML file. I do not have a database and this isn't integrating into an existing site. It is just for my personal use.