Discussion Locked

Help with sorting form fields

0 helpful
1 reply
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I recently desinged a pretty simple form (mixture of text fields, radio buttons, and menus) and I'm having a problem with how my server sorts the fields. When I receive the form email, all the fields are completely out of order. I've tried adding a hidden sort field to specify the order

but it didn't solve the problem. Is there any other code I could use? Maybe something to add into the ASP file?

Here is the code for the ASP file (sendmail.asp) I'm currently using:

<%
for each key in request.form
eBody = eBody & key &": " &request.form(key) &chr(10)
next

SET JMail = Server.CreateObject("JMail.smtpmail")
JMail.ServerAddress ="formmail.strongsecure.com"
JMail.Sender = request.form("Email")
JMail.Subject = "KK Form"
JMail.AddRecipient "info@kksound.com"
JMail.Body = eBody
JMail.Execute
SET JMail = Nothing

%>

Thanks.

1 reply

by boymackman

The only way that I know of is to add each form entry into the code in the .body section.

That way it will list them in the order that you want, it may be a little time consuming but it will give you the ordering.

This discussion is closed to new replies.