So I have this form:
<form method="POST" action="/parse">
<div>
<input name="photo[0]" value="Hey I'm photo zero!" />
</div>
<div>
<input name="photo[1]" value="Photo one here!" />
</div>
<div>
<input name="photo[2]" value="Awh I'm photo 2 but I'm the third photo..." />
</div>
<div>
<button type="submit">submit</button>
</div>
</form>
In Go, it appears, the net/http library will allow you to query the form data one at a time by string key in the form:
r.PostFormValue("photo[0]")
Is there an easy way to parse this form directly as a slice in Go?
That is, being able to access the elements of photo like this:
photos := r.PostFormValue("photo");
log.Println(photos[1]);
Or any other suggestion on properly accessing 'array like' data structures in form post data in Golang aside from string munging...