473,320 Members | 2,012 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,320 software developers and data experts.

POST or SESSION ?

Hello all,
I am working on some simple pages that pass non-critical information (i.e.
no passwords, usernames, etc.)
to and from different pages. Currently, I am using FORMs w/the POST method.
I am not using any cookies or anything stored on the client end, simply
passing data.

Should I read up on SESSIONS and use those instead of POST ? What are the
benefits/drawbacks
by switching to SESSIONS ?

Many thanks.
Jul 17 '05 #1
3 9137
StinkFinger wrote:
I am working on some simple pages that pass non-critical information (i.e.
no passwords, usernames, etc.)
to and from different pages. Currently, I am using FORMs w/the POST method.
I am not using any cookies or anything stored on the client end, simply
passing data.

Should I read up on SESSIONS
Yes.
and use those instead of POST ?
Probably yes.
What are the benefits/drawbacks by switching to SESSIONS ?


POST data can be changed by the user (even hidden fields);
session variables cannot.

POST data has to travel back and forth through the 'net;
session variables never leave the server.

.... more differences .... anyone?

--
USENET would be a better place if everybody read: : mail address :
http://www.catb.org/~esr/faqs/smart-questions.html : is valid for :
http://www.netmeister.org/news/learn2quote2.html : "text/plain" :
http://www.expita.com/nomime.html : to 10K bytes :
Jul 17 '05 #2

"Pedro Graca" <he****@hotpop.com> wrote in message
news:sl*******************@ID-203069.user.uni-berlin.de...
StinkFinger wrote:
I am working on some simple pages that pass non-critical information (i.e. no passwords, usernames, etc.)
to and from different pages. Currently, I am using FORMs w/the POST method. I am not using any cookies or anything stored on the client end, simply
passing data.

Should I read up on SESSIONS
Yes.
and use those instead of POST ?


Probably yes.


It's entirely dependant on the sort of data transferred between the client
and the server. No method is a particular best practise. If a lot of the
data transferred is intended to be persistent throughout a browsing session,
you should most definitely use sessions. If each transaction deals with
unique (ie. non-persistent) data, you probabely don't need sessions.
What are the benefits/drawbacks by switching to SESSIONS ?


POST data can be changed by the user (even hidden fields);
session variables cannot.


POST data is the responsibility of the client, and is only stored/maintained
by the client. Session variables are never seen by the client, and their
maintenance and storage is the responsibility of the server. There are
performance and maintenance implications on the server-side, as storage and
destruction of this data must be managed by the server.

For large webservers, this may be an issue. For smaller webservers, the only
real concern is the required infrastructure to support session data storage.
You will have to weigh this up when deciding if sessions are appropriate.

POST data has to travel back and forth through the 'net;
session variables never leave the server.


Another consideration.

Nathan
Jul 17 '05 #3
Thanks everyone - all my questions (for now ;) have been answered.

"Nathan Gardiner" <na**@nate.id.au> wrote in message
news:40********************@news.astraweb.com...

"Pedro Graca" <he****@hotpop.com> wrote in message
news:sl*******************@ID-203069.user.uni-berlin.de...
StinkFinger wrote:
> I am working on some simple pages that pass non-critical information (i.e. > no passwords, usernames, etc.)
> to and from different pages. Currently, I am using FORMs w/the POST method. > I am not using any cookies or anything stored on the client end, simply
> passing data.
>
> Should I read up on SESSIONS


Yes.
> and use those instead of POST ?


Probably yes.


It's entirely dependant on the sort of data transferred between the client
and the server. No method is a particular best practise. If a lot of the
data transferred is intended to be persistent throughout a browsing
session,
you should most definitely use sessions. If each transaction deals with
unique (ie. non-persistent) data, you probabely don't need sessions.
> What are the benefits/drawbacks by switching to SESSIONS ?


POST data can be changed by the user (even hidden fields);
session variables cannot.


POST data is the responsibility of the client, and is only
stored/maintained
by the client. Session variables are never seen by the client, and their
maintenance and storage is the responsibility of the server. There are
performance and maintenance implications on the server-side, as storage
and
destruction of this data must be managed by the server.

For large webservers, this may be an issue. For smaller webservers, the
only
real concern is the required infrastructure to support session data
storage.
You will have to weigh this up when deciding if sessions are appropriate.

POST data has to travel back and forth through the 'net;
session variables never leave the server.


Another consideration.

Nathan

Jul 17 '05 #4

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

Similar topics

7
by: ehendrikd | last post by:
hi all i need some clarification on how the php session work in relation to cookies. we have a web site where users need to log in. a few of our users were having troubles with their browser...
14
by: Paul Yanzick | last post by:
Hello, I am trying to develop a book tracking application for my capstone in school, and am running into a problem. The application is an ASP.Net application written in C#. The first page you...
4
by: Andy | last post by:
We currently use an online Task Management System that uses a login form. This System has some reports that can be ran, however: you must do them individually and also log-in to the system. This...
5
by: Vishal | last post by:
Hello, I already asked this question in the ASP.NET forums, but no help came. So I am hoping that somebody can help me out. This is really very URGENT me. For my e-commerce application, I...
4
by: Chris Newby | last post by:
My project currently requires that I integrate an ASP.NET application with an ASP application. One of the issues I'm having is that I have some very long strings being created in an ASP.NET...
4
by: Aidas Pasilis | last post by:
I'm saving some values to the Session state and get some strange results. To be short I'll write example code and standart behavior: Code Example:...
4
by: Gaetan | last post by:
I have an ASP.Net 1.1 application using datagrid. I am trying to handle conditions where the users post back an updated datagrid after the session times out. The results are not pretty. Sometimes...
3
Unicron
by: Unicron | last post by:
Hi folks, I have been working on a property listing search for a company for a while now and have hit a roadblock. I have searched the net up and down. A lot of Google results lead to this site, but...
4
by: museumoftechno | last post by:
Hello I'm new to PHP session variables, and I'm doing some work for a client whose website uses session variables in a form that contains image verification. There's a problem with the form - it...
1
by: rienh | last post by:
I'am using Adam's pagination script from: http://www.developphp.com/view_lesson.php?v=289 And I adjusted the code just a little, so it fitted my needs. Now I bumb into a problem, and I can't figure...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.