473,508 Members | 2,140 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

session varible problem

Hi guys,

I’m facing some problem can u solve it.

Problem is:
I’m giving user Id and password in (Login_sess.asp) and submit it to page
(sess_test.asp). I am setting session variable (session(“Sin”)=”Yes”) just
before redirecting to the same page, but in first time I do not received the
value of session variable when I redirect it, when I execute this process
second time or redirect it only with the page name (sess_test.asp) it
receives session value.

Can you tell me what’s the problem?
I’ve to receive session value in first time and have to redirect with
compete URL
Login_sess.asp (Page is)

<%@ Language=VBScript %>
<html><head>
<title>Login </title>
</head>
<h1 align=center>Login in Your Account </h1>
<BODY>
<form name=login method=post action=sess_test.asp >
<table width=40%>
<tr><td colspan=2>Type Your ID and Password</td></tr>
<tr><td>Enter Your ID</td><td><INPUT type="text" id=txtUID name=txtUID
</td></tr>

<tr><td>Password </td><td><INPUT type="text" id=txtPwd name=txtPwd ></td></tr>
</table>

<table width=40%><tr><td align=center><INPUT type="submit" value="Submit"
id=submit name=submit>
&nbsp&nbsp <INPUT type="reset" value="Reset" id=reset name=reset >
</td></table>
</form></BODY></HTML>
Sess_test.asp (file is)
<%@ Language=VBScript %>
<html><head><title>Main Page </title></head>
<body><form method=get>
<%Response.Write "session Variable =" & Session("Sin")
if Request("txtUID") <> "" then
Session("Sin")="Yes"
Response.Redirect "http://localhost/sg/sess_test.asp"
'Response.Redirect "sess_tes.asp"
end if %>
<br><A href="Login_sess.asp">Sin In</A>
</body></form>
</HTML>

regards,
farooq



Jul 22 '05 #1
0 1085

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

Similar topics

3
1619
by: prash | last post by:
Hello all I have a strange problem at the moment .I use iis5 to do my asp pages with vb scripts when i set session("myvar")="anyvalue" in my first page i cannot read the session variable in...
0
1469
by: Aarchaic | last post by:
Hello i have problem my session variables seem to disapear as i go along i've created this code to ilustrate whats happening First off i just post 3 detials like a name a age and a favourite...
0
1014
by: Hrvoje Vrbanc | last post by:
Hello all, I have recently encountered a very strange problem: on every redirect from a codebehind page, sessions break. A varible is correctly stored in a session on a page and then, when a...
9
1728
by: arial | last post by:
Hi all, I have problem with session variable on .net web form. I am saving ID in session to pull up the other .net web form it works fine with my development environment but as soon as I put...
0
7227
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
7331
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,...
1
7054
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7501
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...
0
4713
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3188
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1564
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
768
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
424
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.