Difference between remoting and webservice.Difference between machine.config and web.config.Application life cycle.
Inbox
X

| difference between remoting and web service in .ne... | |||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||
| January 07, 2006 06:45:29 | #2 | ||
| Amarpreet S. Rajwans | |||
| RE: What is the difference between web.config and mach... | |||
| Web.config file Setting of asp.net all porject mach.config are setting of server setting and when the web side are implemented time it work all project but web.config file set all projects | |||
| | |||
| January 13, 2006 08:23:50 | #3 | ||
| sabir | |||
| RE: What is the difference between web.config and mach... | |||
| web config will be for that paticlur aplln whereas the manchine .config will for the whole machine | |||
| | |||
| February 08, 2006 15:39:22 | #4 | ||
| Shree | Member Since: October 2005 Contribution: 3 | ||
| RE: What is the difference between web.config and mach... | |||
| Every ASP.NET application that you has a web.config file . The settings specified in this will imply only to that application.Whereas Your System will have a machine.config file in Microsoft.NET\Framework\v1.1. | |||
| | |||
| March 03, 2006 04:30:41 | #5 | ||
| Nitin | |||
| RE: What is the difference between web.config and mach... | |||
| Web.config file is to override the settings from the machine.config file. machine.config file settings are applied to all the webapplications residing on the server while web.config settings are application specific. | |||
| | |||
| March 06, 2006 04:07:00 | #6 | ||
| Markivir | |||
| RE: What is the difference between web.config and mach... | |||
| Web.config file is to override the settings from the machine.config file. machine.config file settings are applied to all the webapplications residing on the server while web.config settings are application specific. | |||
| | |||
| April 23, 2007 11:09:04 | #7 | ||
| Muralidharan | |||
| RE: What is the difference between web.config and mach... | |||
| machine.config is created when you install ASP.NET in your machine Web.config is created when you create an application | |||
| | |||
| April 08, 2008 06:31:07 | #8 | ||
| Pallav1984 | Member Since: April 2008 Contribution: 1 | ||
| RE: What is the difference between web.config and machine.config ? | |||
| web.config is configure ur apllication only but machine.config file related to ur all d application on ur server. | |||
| | |||
| June 02, 2008 03:33:42 | #9 | |
| tarunrawat4u | Member Since: June 2008 Contribution: 2 | |
| RE: What is the difference between web.config and machine.config ? | ||
| The MACHINE.config file contains default and machnine-specific values for all supported setting. Machine setting are normally controlled by the system admin, and app should never be given write access to it. An application can override most default values stored in the machine.config file by creating one or more web.config files. At min, an app creates a WEB config file in its root folder. The web.config file is a subset of machine.config written according to the same XML achema. | ||
As far as my knowledge is concerned, cookies are stored on client side where as sessions are server variables. The storage limitations are also there (like IE restricts the size of cookie to be not more than 4096 bytes). We can store only a string value in a cookie where as objects can be stored in session variables. The client will have to accept the cookies in order to use cookies, there is no need of user's approval or confirmation to use Session variables cos they are stored on server. The other aspect of this issue is cookies can be stored as long as we want(even for life time) if the user accepts them, but with session variables we can only store something in it as long as the session is not timed out or the browser window is not closed which ever occurs first.
Coming to usage you can use both cookies and session in the same page.
We should go for cookies to store something that we want to know when the user returns to the web page in future (eg. remember me on this computer check box on login pages uses cookies to remember the user when he returns). Sessions should be used to remember something for that particular browser session (like the user name, to display on every page or where ever needed).
how to write and read cookies.
This eample code belongs to web site www.gotdotnet.com visit the following link for full example code and demo.
http://samples.gotdotnet.com/
Protected Sub Page_Load(sender As Object, e As EventArgs)
If Request.Cookies("preferences1"
Dim cookie As New HttpCookie("preferences1")
cookie.Values.Add("ForeColor", "black")
...
Response.AppendCookie(cookie)
End If
End Sub
Protected Function GetStyle(key As String) As String
Dim cookie As HttpCookie = Request.Cookies("preferences1"
If cookie <> Null Then
Select Case key
Case "ForeColor"
Return(cookie.Values("
Case ...
End Select
End If
Return("")
End Function
How to write and read session variables.
This example belongs to www.eggheadcafe.com visit the following link for quick summary and list of FAQs on Session State.
http://www.eggheadcafe.com/
Basic use of Session in ASP.NET (C#):
STORE:
DataSet ds = GetDataSet(whatever parameters);
Session["mydataset")=ds;
RETRIEVE:
DataSet ds = (DataSet)Session["mydataset"];
Good Luck,
Sai Puli.
Above answer was rated as good by the following members:
satyanis1
| March 16, 2006 17:14:00 | #1 | |
| billmaher | Member Since: October 2005 Contribution: 2 | |
| RE: What is the difference between Session and Cookies... | ||
| As far as my knowledge is concerned, cookies are stored on client side where as sessions are server variables. The storage limitations are also there (like IE restricts the size of cookie to be not more than 4096 bytes). We can store only a string value in a cookie where as objects can be stored in session variables. The client will have to accept the cookies in order to use cookies, there is no need of user's approval or confirmation to use Session variables cos they are stored on server. The other aspect of this issue is cookies can be stored as long as we want(even for life time) if the user accepts them, but with session variables we can only store something in it as long as the session is not timed out or the browser window is not closed which ever occurs first. Coming to usage you can use both cookies and session in the same page. We should go for cookies to store something that we want to know when the user returns to the web page in future (eg. remember me on this computer check box on login pages uses cookies to remember the user when he returns). Sessions should be used to remember something for that particular browser session (like the user name, to display on every page or where ever needed). how to write and read cookies. This eample code belongs to web site www.gotdotnet.com visit the following link for full example code and demo. http://samples.gotdotnet.com/ Protected Sub Page_Load(sender As Object, e As EventArgs) Protected Function GetStyle(key As String) As String How to write and read session variables. This example belongs to www.eggheadcafe.com visit the following link for quick summary and list of FAQs on Session State. http://www.eggheadcafe.com/ Basic use of Session in ASP.NET (C#): STORE: RETRIEVE: Good Luck, Sai Puli. | ||
| RE: Explain the life cycle of an ASP .NET page. | ||
| Events in ASP.Net 1.1 & 2.0 :-
Application: BeginRequest |
No comments:
Post a Comment