User Comments on 'Using Cookies in ASP.NET'
|
Posted by :
Archive Import (Rmw) at 10:41 on Friday, February 14, 2003
|
I want to use cookies/sessions to restrict people login to some of my web pages in the site. Only people who have logged in should havce access to certain pages. How can I do this ?
| |
Posted by :
Archive Import (Trev) at 12:12 on Friday, March 14, 2003
|
Session["LoggedIn"] = True
if(Convert.ToBoolean(Session["LoggedIn"]==true)
{
// then they can see the page
}
else
{
Response.Redirect("can'tsee.html");
}
| |
Posted by :
Archive Import (Lightsabre) at 15:34 on Thursday, March 20, 2003
|
I've seen and error tested the need for System.Net in order to use cookies. Anyone else encounter this?
| |
|
|
Posted by :
narayan at 01:41 on Thursday, November 25, 2004
|
i want my asp.net page to detect the cookie settings of my browser.It will be more helpful if it can detect all browser settings.
Thank You.
| |
Posted by :
rajp at 02:05 on Saturday, February 10, 2007
|
how can i get top 5 value from the table in a single query.
| |
Posted by :
raju.msoftprof at 07:05 on Thursday, October 18, 2007
|
use this code. it works
if(Session["loggedin"]!=null)
{
//then they can see the page
}
else
{
Response.Write("Please Log in");
}
| |
Posted by :
zawphyoaye at 20:28 on Sunday, December 16, 2007
|
I used login control.I want to remember UserName and Password next time in my asp.net page.How can i do this?
| |
Posted by :
faez at 02:30 on Tuesday, March 17, 2009
|
This piece of code does'nt work because in the if statement closing braket is missing
Session["LoggedIn"] = True
if(Convert.ToBoolean(Session["LoggedIn"]==true)
{
// then they can see the page
}
else
{
Response.Redirect("can'tsee.html");
}
This code should be...
Session["LoggedIn"] = True
if(Convert.ToBoolean(Session["LoggedIn"]) ==true)
{
// then they can see the page
}
else
{
Response.Redirect("can'tsee.html");
}
Cheerz
Faez(IT Developer)
| |
Posted by :
alexdenipaul at 13:20 on Monday, October 12, 2009
|
Here is a simple solution, only for IE (it uses ActiveX objects, and
gives a security alert with normal preferences set):
var wordDoc=new ActiveXObject('Word.Document');
// creates a new ActiveX object
wordDoc.Application.Visible=true;
// displays the application (Word) with the (empty) document loaded
// ...
// Do here whatever you like
// ... <a href="http://www.hostseeq.com/business/mortgage.htm">commercial mortgage</a>
wordDoc=null; // dispose of the reference
| |
Posted by :
alexdenipaul at 13:21 on Monday, October 12, 2009
|
[url=http://www.codetoad.com/]CodeToad[/url]
| |