Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Alternative to Cookie?

 
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I would like to know what are the other alternative ways to do the work without cookies.

Is there any best ways to implement the application without cookies?


Thanks,


 
Ranch Hand
Posts: 69
Eclipse IDE Firefox Browser Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use session or session id
 
Saloon Keeper
Posts: 22289
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes. URL rewriting. There are several API functions in J2EE to handle URL rewriting.

However, unlike cookies, rewritten URLs are pretty fragile. If someone manually types in a URL, they probably won't type in the extra information relating to the session (and if they type as bad as I do, they'll probably get it wrong). Cookies are handled automatically, and they can be given a specific lifespan.
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hidden fields on Forms work just fine as an alternative to cookies.

Naturally you must ensure that every new request is a POST from a Form.

Bill
 
Ranch Hand
Posts: 129
Firefox Browser Tomcat Server Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Nalini Nagarathinam wrote:
I would like to know what are the other alternative ways to do the work without cookies.

Is there any best ways to implement the application without cookies?







session(HttpSession) will be the most secure option ...
 
Ranch Hand
Posts: 2066
IntelliJ IDE Clojure Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

mahesh shinde wrote:Use session or session id



session stuff is different from cookies. For session tracking purposes, we use cookies, URL rewriting and SSL connections. Don't confuse session with cookies. session are maintained in server side and the cookies are maintained in the client side!
 
mahesh shinde
Ranch Hand
Posts: 69
Eclipse IDE Firefox Browser Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes we use cookie to track session.

so its better to use URLRewriting instead of cookie for session tracking
 
You don't like waffles? Well, do you like this tiny ad?
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic