473,397 Members | 2,056 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

safest way to pass parameters between pages

Hi,

I have a few aspx (.net2) form.

The first form allows the user to enter into text box, and select values
from drop downs

The second form needs to use these values to process some data.

I am currently using the url to pass the values such as
'pagename.aspx?parm1=value&param2=value, and the second form does a
request.headers("parm1")

However this exposes the values in the browser, and I don't want this.

Is there a way to do this where its hidden from the user ?

Thanks

Oct 8 '07 #1
3 3164
"Aussie Rules" <Au*********@nospam.nospamwrote in message
news:u8**************@TK2MSFTNGP03.phx.gbl...
I have a few aspx (.net2) form.

The first form allows the user to enter into text box, and select values
from drop downs

The second form needs to use these values to process some data.

I am currently using the url to pass the values such as
'pagename.aspx?parm1=value&param2=value, and the second form does a
request.headers("parm1")

However this exposes the values in the browser, and I don't want this.

Is there a way to do this where its hidden from the user ?
Generally speaking, in ASP.NET there is no need to use two forms for this -
that is what a postback is for...

When the user clicks the <asp:Button>, the form will postback and the values
in the textboxes will be available for you to do your processing.
Afterwards, you can redirect to another page if you like, but there's no
need to...

http://www.google.co.uk/search?sourc...ET%22+postback
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Oct 9 '07 #2
Where did you get this "request.headers("parm1") stuff?
Your stuff is on the QueryString. You would get it with
Request.QueryString("parm1") or
Request.Params("parm1")

-- Peter
Recursion: see Recursion
site: http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com

"Aussie Rules" wrote:
Hi,

I have a few aspx (.net2) form.

The first form allows the user to enter into text box, and select values
from drop downs

The second form needs to use these values to process some data.

I am currently using the url to pass the values such as
'pagename.aspx?parm1=value¶m2=value, and the second form does a
request.headers("parm1")

However this exposes the values in the browser, and I don't want this.

Is there a way to do this where its hidden from the user ?

Thanks

Oct 9 '07 #3

Hi Aussie,

Generally, for share data between web pages, you can use querystring,
session, database ........ However, for ASP.NET 2.0 page, it also provide
some particular features, such as the cross page postback(if you are using
submit/postback to redirect to other page). Or you can use Server.Transfer
to redirect page and use HttpContext.Items collection to store temp data.
Here is a msdn reference mentioend some of them:

#How to: Pass Values Between ASP.NET Web Pages
http://msdn2.microsoft.com/en-us/lib...fw(VS.80).aspx

BTW, do you think the suggestion that use single page with postback from
other members also possible for your case?

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>From: "Aussie Rules" <Au*********@nospam.nospam>
Subject: safest way to pass parameters between pages
Date: Tue, 9 Oct 2007 00:22:22 +0100
>Hi,

I have a few aspx (.net2) form.

The first form allows the user to enter into text box, and select values
from drop downs

The second form needs to use these values to process some data.

I am currently using the url to pass the values such as
'pagename.aspx?parm1=value&param2=value, and the second form does a
request.headers("parm1")

However this exposes the values in the browser, and I don't want this.

Is there a way to do this where its hidden from the user ?

Thanks

Oct 9 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Ravi & Paami | last post by:
After I tried upgrading my php version from 3 to 4, all my code which passes parameters between web pages have stopped working. Not sure what the problem is. Have tried defining the parameters in...
7
by: Zlatko Matić | last post by:
Let's assume that we have a database on some SQL server (let it be MS SQL Server) and that we want to execute some parameterized query as a pass.through query. How can we pass parameters to the...
0
by: Zlatko Matić | last post by:
Hi everybody! Recently I was struggling with client/server issues in MS Access/PostgreSQL combination. Although Access is intuitive and easy to use desktop database solution, many problems...
7
by: Spongebob | last post by:
Hello, I have a question about how to pass information between pages in ASP.NET. There are 2 pages : page1.aspx, page2.aspx. On page1 user clicks the record. Then, I need to show the detailed...
9
by: Alan Silver | last post by:
Hello, I'm a bit surprised at the amount of boilerplate code required to do standard data access in .NET and was looking for a way to improve matters. In Classic ASP, I used to have a common...
2
by: rinat | last post by:
Hi, I have an aspx page who needs to open a asp page and pass some text parameters to it, I would have used the request.querystring but I'm afraid the data is too long. is there an option to...
0
by: H5N1 | last post by:
Hi there I know that a problem of different datetime strings formatting between asp.net and ms sql has been covered here widely, but what I couldn't find is the 100% safe way of getting datetime...
2
by: gumby | last post by:
I would like to call this stored procedure, but I am unable to pass parameters to the @Start and @End. Is thier a way to pass parameters to a pass through query from MS Access? SELECT ...
2
by: =?Utf-8?B?U3RldmVuIFRhbmc=?= | last post by:
I'm creating a XBAP application and want it take some input from webpage dynamically? what is the best way? how to do it? Best Regards Steven -- ======================= Steven Tang SYWWUYU)
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.