Get ready for BLACK FRIDAY shopping starting in

Forums

This topic is locked

Dreamweaver & ASP help

Posted 30 Nov 2004 14:59:41
1
has voted
30 Nov 2004 14:59:41 J E posted:
I am attempting to pass 23 variables to an asp vbscript page for insertion into the database. the form on the 1st page (agroup.asp) passes all the variables with GET to the 2nd page (agroupfunctions.asp)
when I use the server behavior "COMMAND" and select INSERT then fill out all the INSERT INTO () and VALUE () then the vars at the bottom to Request.QueryString("data" 23 times. It never works for me. Is there an easier way of passing variables to insertion page without typing request.form("data" 23 times and I need to do it without doing the insert on the actual form page(thats why im passing the vars). Sound confusing enough?

Thx

Replies

Replied 30 Nov 2004 15:37:07
30 Nov 2004 15:37:07 Lee Diggins replied:
It does!

Do all the name/value pairs in the querystring or form have unique names?

Digga

Sharing Knowledge Saves Valuable Time!!!
Replied 30 Nov 2004 15:45:41
30 Nov 2004 15:45:41 Simon Martin replied:
Is the data being sent what you would expect?

I use the following to help debug when I get stuck - I can't take the credit for it as I didnt write it, but equally I can't remember where I found it now.

<% Option Explicit %>
<html>
<!-- head tag -->
<body>

<%
dim fld

response.write "Result from: " & request.serverVariables("HTTP_REFERER"
response.write "<table>"
response.write "<tr><td>Field</td><td>Value</td></tr>"
for each fld in request.form
response.write "<tr><td>" & fld & "</td><td>" & request.form(fld) & "</td></tr>"
next 'fld
response.write "</table>"

%>

</body>
</html>

Live the life you love
Love the life you live

Simon

[DWMX 2004]|[SQL]|[ASP/VBScript]|[XP-Pro]

Reply to this topic