Passing email in string from one page to another.

M

Miguel Orrego

Hi,

I have a page that pulls data from a database, one of the fields is Notetext
which frequently contains an email. I then want to pass this onto another
page, that updates the email field in another database, so in page 1:

strNote = rsnotes("NOTETEXT")

And to pass to the next page:

<a
href="createemail.asp?strIssueNo=<%=zero(rsnotes.fields(0))%>&strNote=<%=str
Note%>"><img src="Images/createemail.gif" width="75" height="25"></a>

It all works fine except that only about half the email gets copied into the
other database. It's not an issue with the database as it can take that
length of characters.

So my question, Is there a limit to the number of charachters you can pass
from one page to another in a string? and if so is there any way of
increasing this or getting around it?

Thanks.
 
K

Ken Schaefer

a) If you want to pass data in the querystring you need to use
Server.URLEncode() on the data, ie:

<a href="newpage.asp?var=<%=Server.URLEncode(strVar)%>">click</a>

because some of the characters are not legal in querystrings, and need to
encoded

b) Why don't you just pass the Primary Key value of the record in question,
and then use that to do a lookup on the record on the next page?

<a href="newpage.asp?recordID=5">click here</a>

Cheers
Ken



: Hi,
:
: I have a page that pulls data from a database, one of the fields is
Notetext
: which frequently contains an email. I then want to pass this onto another
: page, that updates the email field in another database, so in page 1:
:
: strNote = rsnotes("NOTETEXT")
:
: And to pass to the next page:
:
: <a
:
href="createemail.asp?strIssueNo=<%=zero(rsnotes.fields(0))%>&strNote=<%=str
: Note%>"><img src="Images/createemail.gif" width="75" height="25"></a>
:
: It all works fine except that only about half the email gets copied into
the
: other database. It's not an issue with the database as it can take that
: length of characters.
:
: So my question, Is there a limit to the number of charachters you can pass
: from one page to another in a string? and if so is there any way of
: increasing this or getting around it?
:
: Thanks.
:
:
:
:
:
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top