How to pass variables within pages without showing it in URL and not using session variables

My aspx page need to be called from within another page.

My page must receive 2 values (variables) form the page that will request may page, and  must hide these values (it can not appear in the URL).

It seems that I must use  the get/post method, but Idont know how.

Can someone show me a example with 2 small pages showing how one page can request another passing values (not showed in the URL)

 

 

tanks in advance

 

0
bastiaanwilderom
8/18/2006 8:49:32 PM
asp.net.web-forms 93655 articles. 6 followers. Follow

3 Replies
1035 Views

Similar Articles

[PageSpeed] 37

Take a look at this...

http://www.codeproject.com/aspnet/DataPassingBtPages.asp?df=100&forumid=109242&exp=0&select=930900


Steven M. Swafford
http://aspalliance.com/author.aspx?uId=1158

Dont forget to click "Mark as Answer" on the post that helped you.
0
StevenSw
8/18/2006 11:50:28 PM

Thanks  Steven, it resolved one of my problems when both pages are aspx pages.

 

But I have another situation where the first page is writen using PHP, and passes variables using POST/GET method and need to request  a second page writed in Aspx.

Is it possible from the second page(writed in aspx), to be executed  reading the values of the variables from PHP ? 

0
bastiaanwilderom
8/19/2006 12:41:19 PM

you could use

Request.Form[name]  to get POST value, and

Request.QueryString[name] to get GET value.

alternatively,

store value in cookies or database is doable.

 

0
Dragon
8/21/2006 3:31:10 AM
Reply:

Similar Artilces:

Passing data between web form pages without use of parameter/URL strings
Hi folks. I'd like to be able to pass data between web form pages (VB.NET, if it matters) without use of parameter strings in the URL (i.e. address?&parameter=value). If memory serves, it's possible to pass data 'behind the scenes'. How do I do that? If there's many ways of doing this, would you mind summarising each? In principle it sounds a more secure method than using parameters, which could be abused. Thanks. :) You can use session items. First Page Session.Item("Value1") = TextBox1.Text You can then refer to that session item in your other pages or use...

Passing A Session Variable Form Page to Page ~ No Working
Hi All, I am trying to passing a session variable from Page to Page but its not working! the user basicaly logins in on the login.aspx and when their credentials are verifed by the MSSAccess database they are tehn redirected to the next page...heres a snip of code ~~~~~~~~~~~~~~ session("ID") = dslogin.tables("UserInfo").rows(0).item("ID") response.redirect("./success.aspx") ~~~~~~~~~~~~~~~~~~ Heres the code for the page I am trying to access after beigng verifed ~~~~~~~~~~ sub page_load(byval sender as object, b...

Passing a variable to another page in a session variable
I want to pass a string to another page I'm opening with JavaScript using a session variable. The problem is, I might be opening 3 or 4 instances of this new window at the same time and I will need to pass a different value to each instance. Is there a good way to do this? well, the process you describe is off. there is no "passing", really, when using session state. once it's in there, it's in there across ALL page requests (even if that page request is opened through a javascript window.open() method). So it won't matter how many pages you access, or how many times, once it...

How can I use a variable passed to a page in the URL?
I need to produce a page that displays a GridView where the items in the gridview are hyperlinked to their own page.  I have worked out how to produce the hyperlinks in the GridView page and construct the URL to include the appropriate query string.My problem is that I do not know how to use the query string in the new page.  Would somebody be able to show me how I can use a URL such as http://localhost:1884/newpage.aspx?product_id=7 so that in the new page I have a simple label with text of "7"? Many thanks in advance.  Hi, in the second page you can, in the...

Pass variables between web forms within the same masterpage?
Hi,I'm trying to pass some variables between two web forms that are placed in content place holders in the same master page, in my eyes, this must be possible!? How can I make this happen? Thanks guys! //Anders (SWE)//KyotoKiller [SWE] There a several solutions:You can for example make sure values are stored between pages with a Session variable. You can use QueryStrings that passes the value to another page.Use PostBackUrl property of a Button control: http://fredrik.nsquared2.com/viewpost.aspx?PostID=147 /Fredrik Normén - fredrikn @ twitterMicrosoft MVP,...

Passing form variable from page to page
I have application which requires to pass form variables from page to page.   Basically, it's registraion web site. I have 4 diffferent page which collect information from end user. For example: Page 1: default.aspx Page 2: Survey.aspx Page 3: Profile.aspxPage 4: Classes.aspxPage 5: payment.aspxPage 6: Finished.aspx So, at the end of page 6, i would like collect all the form variables and then insert into database. thanksaj This may not be the answer for which you're looking, but this might be wll suited to using a wizard all on one page.....just...

How can i pass a variable to pages by using session or else?
1. After login, user will go home page. 2. After validate the username and password, how can i pass the username/userid to other page when i click on a button which the command is response.redirect("otherpages.aspx?u_id=userid") That's a very bad idea. You should store it in a session variable and then access the session variable. By passing it in a querystring, you will still need a way to validate that they say who they are and not trying to access somebody elses page. Setting the session: Session["Username"] = SomeValue1;Session["UserID"] = SomeValue2; Getting the session: SomeVari...

Passing variable using linkbutton without page redirect?
being a novice programmer, what is the best way to pass a variable to a sqldatasource control?  I am just tring to update a detailsview sqldatasource to show an image with a linkbutton so that when you click the linkbutton it changes from one to the other.  this might be using continually updating data at some point, but right now just bringing up different gif files. however, i only know how to use response.redirect in the page load event handler.  how can i update this variable ISU = "NASD" or whatever without having to reload the page?  the dataview co...

Losing session variables when using redirect to new web page
Hi All   I have an application which involves a sign up process where i store details filled in separate screens in session variables  movement between pages is by clicking on a button which redirects user to next page, all because i though button looked neater plus at least 1 screen uses a button in a datagrid for navigation Its being behaving erratically for a while, finally i was updating whole site an discovered that most of the time session variable are wiped out I guess this tells me one reason why the websites sign up rate is abysmal   I found another thread abo...

Who to passing a Variable One web page to other page ??
Who to passing a Variable One web page to other page ?? pl. also differant way of passing variable one page to other page If you find it absolutely necessary to pass values between pages (which is the Classic ASP way of dealing with things) you could read this: Passing Server Control Values Between PagesRegardsAndre Colbiornsen ---------------------------------Seventh DayRåbygatan 1A,SE-223 61 LundSwedenMob.: +46-(0)708-97 78 79Mail: info@seventhday.se--------------------------------...

Session passing variables Using Session ID
I am passing variables using session ID . When multiple people sign-on to the server, the session ID is passed corectly, but the name and user ID are for the person that signed in first. That is both people get the same information, when it should be customized for each. I am using IIS version 7. SendingHttpContext.Current.Session("Session_ID") = Session.SessionID HttpContext.Current.Session("StudentName") = FirstLastHttpContext.Current.Session("StudentNumber") = StudentNumber Response.Write(FirstLast) Response.Write(StudentNumber) Response.Redirect(&quo...

How can I use a variable on my entire application without using Global Variable?
Hi. At the sign on screen of my application, I get from the employee table ten field of data. This fields indicated the privileges of what the user has authority to work on. The question is, how can I use this ten field all over my application without using Global Variable? Structure, I think will not work because it get destroyed unless there is a Global Structure. If somebody knows please let me know. Will still look on the help of PB. Thanks Edgar The PFC handles this by the use of a single global variable - an NVO. The alternative is to have this in an NVO that ...

Passing a JavaScript variable in a URL as a variable
I have a variable that is in my javascript code. I would like to create a url with variables from javascript to pass to another page. Example: <a href=http://www.bla.com/test.aspx?var1="jsvar1"&var2="jsvar2"onclick="hide PopupMenu();">Mark</a> What would be the best way of doing this that I can place on a web page? Example of code I am trying to use this in:http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2152363&SiteID=1  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http:/...

Use of Application Variable and Session Variable
Hi all, please someone tell me when should a Application variable be used and in what conditions a session variable should be used? regards Subhajit As the name of the variables suggest, an Application variable is suitable when the value of this variable should be available to all users of your application from the point the Application is started for the first time. A Session variable, on the other hand, may be different for different users and only exists for the duration of a users visit to your application or until it times out. Hth.RegardsAndre Colbiornsen ----------------...

Web resources about - How to pass variables within pages without showing it in URL and not using session variables - asp.net.web-forms

Variable - Wikipedia, the free encyclopedia
Text is available under the Creative Commons Attribution-ShareAlike License ;additional terms may apply. By using this site, you agree to the ...

Westpac interest rate rise is one of many variable loan rate rises
WESTPAC is not alone in hitting its owner-occupier customers with a surprise interest rate rise, as dozens of other variable rate home loans ...

Airbnb upgrades variable pricing tool for hosts
Online home rental group Airbnb is rolling out an upgraded variable pricing tool that automatically raises or cuts room rates based on supply ...

Commonwealth Bank raises variable home loan rates
Home owners' mortgage costs are set to rise by hundreds of dollars a year, after the Commonwealth Bank became the latest bank to hike interest ...

CBA lifts variable home loan rates to offset costs associated with stricter capital requirements
The Commonwealth Bank to lift its home loan interest rates independently of the Reserve Bank to partially offset costs associated with stricter ...

Washington Square Signs Spielbergs, Choi Joins Variable and More
... films and an episode of the HBO comedy series "Girls," on which he plays the role of Ray Ploshansky. New York-based creative collective Variable ...

YouTube v10.32 Tweaks Some Interface Elements And Includes Hints About Virtual Reality Content And Variable ...
Forget Update Wednesday! Monday is the new big day. Not only were we treated to the latest M preview release and the official Marshmallow name, ...

"You have to ignore many variables to think women are paid less than men. California is happy to try." ...
Writes Sarah Ketterer in The Wall Street Journal in "The ‘Wage Gap’ Myth That Won’t Die" (which you can get to without subscribing if you Google ...

Cisco Debuts Open Pay Variable Pricing, Updates CCRE
Cisco Debuts Open Pay Variable Pricing, Updates CCRE Channel Partners Kris Snow, president of Cisco Capital, says the company's new Open Pay ...

Expert Reveals the Latest Variable Capacity Technology
Learn about gForce Ultra CRAC equipment, the latest variable capacity technology to lower energy usage and increase reliability.

Resources last updated: 12/8/2015 7:18:03 PM