473,698 Members | 2,445 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

More cookies from one document?

Hi,
how can one HTML document create more than one cookie? I have bloody
long html form, to save all its values in 4KB of one cookie is
impossible...
MM
Jul 23 '05 #1
3 1510
"Martin Mrazek" <mr****@compik. fd.cvut.cz> wrote in message
news:dc******** *************** ***@posting.goo gle.com...
Hi,
how can one HTML document create more than one cookie? I have bloody
long html form, to save all its values in 4KB of one cookie is
impossible...
MM


How did you arrive at the conclusion that a document can create only one cookie?
It seems you need to read-up on the basics of cookie handling.
If you get stuck with some actual code, feel free to post it here.
--
Stephen Chalmers


Jul 23 '05 #2
Stephen Chalmers wrote:
"Martin Mrazek" <mr****@compik. fd.cvut.cz> wrote in message
news:dc******** *************** ***@posting.goo gle.com...
Hi,
how can one HTML document create more than one cookie? I have bloody
long html form, to save all its values in 4KB of one cookie is
impossible. ..
MM

How did you arrive at the conclusion that a document can create only one cookie?
It seems you need to read-up on the basics of cookie handling.
If you get stuck with some actual code, feel free to post it here.
--
Stephen Chalmers


While you can have more than one cookie he is right that many browsers
limit the total size of all a site's cookies to 4k. If this limit
didn't exist, malicious sites could sit there generating cookies until
the user ran out of disk space.

My guess is Martin doesn't have access to server side databases, files,
and scripting languages (php, asp). Cookies aren't meant to store large
amounts of data, more along the lines of a small identification code
your site can read and then extract the relevant data from the site's
own database or stored records.

There's a convoluted way to transfer some of the overhead from cookies
to your web page and that's to profile standard settings.

For instance instead of storing,
verdana-12pt-bold-nounderline-red-green:hover you'd assign a profile
string of say 12. Read the cookie, extract 12 and of course 12 would
assign verdana-12pt etc...

Other than that there's not much else you can do to get around the
restriction. The only real option is to get access to a server side
scripting language and store the user data on the server and use cookies
to identify the record stored in your files.
--
-------------
http://www.hunlock.com -- DHTML for the rest of us.
Jul 23 '05 #3
Thanks both and sorry for unclear question. Of course I know I can store
more values under different cookie names, but as the second of
understood, the problem is, that all cookies from one document seems to
be always in one file limited up to 4kB. That was the point of my
question.

Finally I'm going to restrict functionality of the form on IE and use
ActiveX for saving incomplete-form values on client's disc. Server side
solution is definitelly more friendly to other platform user's, but
there are almost none in the Czech republic among companies who have
obligation to fill this form.

Moreover - you know it - time is pressing and have never programmed
anything on server side...

MM
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #4

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

Similar topics

20
3544
by: Brian Burgess | last post by:
Hi all, Anyone know if this is possible? If so, on which page would the cookie be? .. On the page calling a function defined in the include file? thanks in advance.. -BB
1
2407
by: duane | last post by:
Dear Experts: I have a problem. When you enter the website I am working on, wherever you go within the website, the URL address on the website will display: "http:\\..\index.html", whether you go to "Page1.html", "Page2.html", etc. The cookies in every page is set on "<BODY onLoad = "setCookie();">. Except for index.html, all the cookies are set and written to a textfile correctly in the server. All cookie values in
1
1546
by: Karl | last post by:
Hi there! I have a big Problem with some Javascript: On a website, i want to paste some "confirm", if the visitor's browserlanguage is not "de". when he confirm, he'll be redirected to the english-translation of this page. to store this information, because it's ugly to ask on every single visit, if he want to switch to the translation.
1
5432
by: Robert Oschler | last post by:
I have two sites, both with valid P3P policies that passed the W3C P3P validator, including the P3P compliant HTTP headers test. On one of the sites, Site A, I have a web page that loads a document from Site B in an IFRAME. In this context the web page on Site A is the "originating" document and the web page on Site B is a 3rd-party document (since it's from a different domain). I thought that having a valid P3P policy would make IE6...
0
1514
by: Amit Jamgade | last post by:
Hi, I am making use of cookies to store the Session State information through JavaScript as given below in an ASP Page. Suppose I have XYZ.asp page. The code in this page goes as shown below. ********************************************************* <% 'Remark: ASP Code here dim staffID dim TaskCD
10
1879
by: Stephan Schulz | last post by:
Hi all, I'm fairly new to JavaScript, and couldn't find a way to solve the following problem: I've written an application in DHTML/JavaScript, for one because I want to be able to offer access on the web, but primarily because it was the easiest way for me to combine GUI and layout in a portable manner.
1
2485
by: FishKeeper | last post by:
I'm trying to write JavaScript code to test whether cookies are enabled by writing a cookie and then reading its value. My code works fine in Firefox, but it's not working in Internet Explorer 6. I have my privacy settings set to block all cookies, but my JavaScript can read and write cookies. Does this setting just block server cookies? That doesn't seem right. I can't find any other settings that deal with cookies in IE. Here's a...
12
7775
by: Don Juan | last post by:
I have a simple html document I have been using for some time on my (i.e.) abc.com domain that uses cookies. I recently purchased a new domain name and set up a service to redirect my new domain (i.e.) xyz.com to a sub-directory of the abc.com domain. In other words, when someone goes to URL xyz.com, they really end up in abc.com/xyz directory but the MSIE browser says they are xyz.com. The problem is that cookies quit working in this...
7
10204
by: cmrchs | last post by:
Hi, In Windows Vista: where does asp.net write its cookies? I use HttpCookie objCookie = new HttpCookie("nameCookie"); in Win2000 (and later) they used to be in C:\Documents and Settings\Administrator\Cookies but not anymore
0
8675
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8604
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9029
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8862
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7729
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6521
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5860
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4619
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3050
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 we have to send another system

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.