all groups > inetserver asp general > april 2005 >
I have been trying to figure out why I am getting this message... I have an application that is 20 different ASP pages that works in sequential order (step1, step2, step3...). After each step the app writes the entered text to a cookie. This feature is so that if there is a problem, we can still retrieve the data. This Bad Request error has something to do with the cookie that is written to, because I can go all the way through the app to the last step (step20) and then it gives me a Bad Request. If I clear my cookies then it works fine, until step 20 again. Does anyone know what may be going on here? I am guessing that it has to do with the size of the cookie, but I am unsure how I can accomplish this task (allowing the entered data to be retrieved) without cookies. Thanks, Drew
How much data is being put in the cookies? I have heard of browser limits on the size but not server-side limits. Could you use hidden form fields instead? -- --Mark Schupp [quoted text, click to view] "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message news:uTISrs1SFHA.3184@TK2MSFTNGP14.phx.gbl... >I have been trying to figure out why I am getting this message... I have an >application that is 20 different ASP pages that works in sequential order >(step1, step2, step3...). After each step the app writes the entered text >to a cookie. This feature is so that if there is a problem, we can still >retrieve the data. > > This Bad Request error has something to do with the cookie that is written > to, because I can go all the way through the app to the last step (step20) > and then it gives me a Bad Request. If I clear my cookies then it works > fine, until step 20 again. > > Does anyone know what may be going on here? I am guessing that it has to > do with the size of the cookie, but I am unsure how I can accomplish this > task (allowing the entered data to be retrieved) without cookies. > > Thanks, > Drew >
Does the data have to persist past the last step (page 20)? If not, have each page include the data from the previous pages in hidden form fields. If so, a server-side database would be an option (just keep the user id in the cookie). Server-side script cannot write files to the client's system. You could use a component on the client-side to do so but that would require the user to grant permission. -- --Mark Schupp [quoted text, click to view] "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message news:eoEC7a2SFHA.1148@tk2msftngp13.phx.gbl... > The cookie I have on my computer (same error for me) is 13.2KB... > > There is a great deal of data going in there... What about using the FSO > to write to a file? Does FSO have the ability to write to a file on the > client computer? > > Thanks, > Drew > > > "Mark Schupp" <notvalid@email.net> wrote in message > news:OM5l$K2SFHA.2556@TK2MSFTNGP12.phx.gbl... >> How much data is being put in the cookies? I have heard of browser limits >> on the size but not server-side limits. >> >> Could you use hidden form fields instead? >> >> -- >> --Mark Schupp >> >> >> "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message >> news:uTISrs1SFHA.3184@TK2MSFTNGP14.phx.gbl... >>>I have been trying to figure out why I am getting this message... I have >>>an application that is 20 different ASP pages that works in sequential >>>order (step1, step2, step3...). After each step the app writes the >>>entered text to a cookie. This feature is so that if there is a problem, >>>we can still retrieve the data. >>> >>> This Bad Request error has something to do with the cookie that is >>> written to, because I can go all the way through the app to the last >>> step (step20) and then it gives me a Bad Request. If I clear my cookies >>> then it works fine, until step 20 again. >>> >>> Does anyone know what may be going on here? I am guessing that it has >>> to do with the size of the cookie, but I am unsure how I can accomplish >>> this task (allowing the entered data to be retrieved) without cookies. >>> >>> Thanks, >>> Drew >>> >> >> > >
The cookie I have on my computer (same error for me) is 13.2KB... There is a great deal of data going in there... What about using the FSO to write to a file? Does FSO have the ability to write to a file on the client computer? Thanks, Drew [quoted text, click to view] "Mark Schupp" <notvalid@email.net> wrote in message news:OM5l$K2SFHA.2556@TK2MSFTNGP12.phx.gbl... > How much data is being put in the cookies? I have heard of browser limits > on the size but not server-side limits. > > Could you use hidden form fields instead? > > -- > --Mark Schupp > > > "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message > news:uTISrs1SFHA.3184@TK2MSFTNGP14.phx.gbl... >>I have been trying to figure out why I am getting this message... I have >>an application that is 20 different ASP pages that works in sequential >>order (step1, step2, step3...). After each step the app writes the >>entered text to a cookie. This feature is so that if there is a problem, >>we can still retrieve the data. >> >> This Bad Request error has something to do with the cookie that is >> written to, because I can go all the way through the app to the last step >> (step20) and then it gives me a Bad Request. If I clear my cookies then >> it works fine, until step 20 again. >> >> Does anyone know what may be going on here? I am guessing that it has to >> do with the size of the cookie, but I am unsure how I can accomplish this >> task (allowing the entered data to be retrieved) without cookies. >> >> Thanks, >> Drew >> > >
Yeah, I understand your suggestions... Thanks for your help, I am just going to abandon the feature and forget about it! Thanks, Drew [quoted text, click to view] "Mark Schupp" <nospam@nospam.com> wrote in message news:uNdnemATFHA.2768@tk2msftngp13.phx.gbl... > I'm not familiar enough with cookies to help you much (the only cookie we > use is the session cookie). > > Since you have a database available anyway why not keep the data in a > table > in the database? Then just keep a record identifier in the cookie. Your > cookie retrieve/set code would turn into database select/update > statements. > Clear the temporary data when the final update is done. Have a cleanup job > run occasionally to delete abandoned records. > > -- > Mark Schupp > > > > "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message > news:eUbVD5%23SFHA.2756@tk2msftngp13.phx.gbl... >> I am actually inserting this data into a SQL Server database, but I >> wanted >> to implement a "safety net", in case someone has some problems, then we > can >> cut and paste the data back into the app. >> >> My cookie code looks like this, >> >> Dim AllText >> >> If Request.Form("RelationshipsSocialization")<>"" Then >> AllText = Request.Form("RelationshipsSocialization") >> End If >> >> If Request.Form("Communications")<>"" Then >> AllText = AllText & Request.Form("Communications") >> End If >> >> Response.Cookies("ELPStep17")=AllText >> Response.Cookies("ELPStep17").Expires= Now() + 10 >> >> The code fires on the page after the step, i.e. step17's data is put into > a >> cookie and inserted to the DB on step18.asp. >> >> Is it possible to create more than 1 cookie from a domain? My cookies >> now >> look like this, >> >> dlaing@swvtc06[2].txt >> >> Thanks, >> Drew >> >> "Mark Schupp" <notvalid@email.net> wrote in message >> news:%234oGcE3SFHA.3464@tk2msftngp13.phx.gbl... >> > Does the data have to persist past the last step (page 20)? >> > >> > If not, have each page include the data from the previous pages in > hidden >> > form fields. If so, a server-side database would be an option (just >> > keep >> > the user id in the cookie). >> > >> > Server-side script cannot write files to the client's system. You could >> > use a component on the client-side to do so but that would require the >> > user to grant permission. >> > >> > -- >> > --Mark Schupp >> > >> > >> > "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message >> > news:eoEC7a2SFHA.1148@tk2msftngp13.phx.gbl... >> >> The cookie I have on my computer (same error for me) is 13.2KB... >> >> >> >> There is a great deal of data going in there... What about using the > FSO >> >> to write to a file? Does FSO have the ability to write to a file on > the >> >> client computer? >> >> >> >> Thanks, >> >> Drew >> >> >> >> >> >> "Mark Schupp" <notvalid@email.net> wrote in message >> >> news:OM5l$K2SFHA.2556@TK2MSFTNGP12.phx.gbl... >> >>> How much data is being put in the cookies? I have heard of browser >> >>> limits on the size but not server-side limits. >> >>> >> >>> Could you use hidden form fields instead? >> >>> >> >>> -- >> >>> --Mark Schupp >> >>> >> >>> >> >>> "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message >> >>> news:uTISrs1SFHA.3184@TK2MSFTNGP14.phx.gbl... >> >>>>I have been trying to figure out why I am getting this message... I > have >> >>>>an application that is 20 different ASP pages that works in >> >>>>sequential >> >>>>order (step1, step2, step3...). After each step the app writes the >> >>>>entered text to a cookie. This feature is so that if there is a >> >>>>problem, we can still retrieve the data. >> >>>> >> >>>> This Bad Request error has something to do with the cookie that is >> >>>> written to, because I can go all the way through the app to the last >> >>>> step (step20) and then it gives me a Bad Request. If I clear my >> >>>> cookies then it works fine, until step 20 again. >> >>>> >> >>>> Does anyone know what may be going on here? I am guessing that it > has >> >>>> to do with the size of the cookie, but I am unsure how I can > accomplish >> >>>> this task (allowing the entered data to be retrieved) without > cookies. >> >>>> >> >>>> Thanks, >> >>>> Drew >> >>>> >> >>> >> >>> >> >> >> >> >> > >> > >> >> > >
I am actually inserting this data into a SQL Server database, but I wanted to implement a "safety net", in case someone has some problems, then we can cut and paste the data back into the app. My cookie code looks like this, Dim AllText If Request.Form("RelationshipsSocialization")<>"" Then AllText = Request.Form("RelationshipsSocialization") End If If Request.Form("Communications")<>"" Then AllText = AllText & Request.Form("Communications") End If Response.Cookies("ELPStep17")=AllText Response.Cookies("ELPStep17").Expires= Now() + 10 The code fires on the page after the step, i.e. step17's data is put into a cookie and inserted to the DB on step18.asp. Is it possible to create more than 1 cookie from a domain? My cookies now look like this, dlaing@swvtc06[2].txt Thanks, Drew [quoted text, click to view] "Mark Schupp" <notvalid@email.net> wrote in message news:%234oGcE3SFHA.3464@tk2msftngp13.phx.gbl... > Does the data have to persist past the last step (page 20)? > > If not, have each page include the data from the previous pages in hidden > form fields. If so, a server-side database would be an option (just keep > the user id in the cookie). > > Server-side script cannot write files to the client's system. You could > use a component on the client-side to do so but that would require the > user to grant permission. > > -- > --Mark Schupp > > > "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message > news:eoEC7a2SFHA.1148@tk2msftngp13.phx.gbl... >> The cookie I have on my computer (same error for me) is 13.2KB... >> >> There is a great deal of data going in there... What about using the FSO >> to write to a file? Does FSO have the ability to write to a file on the >> client computer? >> >> Thanks, >> Drew >> >> >> "Mark Schupp" <notvalid@email.net> wrote in message >> news:OM5l$K2SFHA.2556@TK2MSFTNGP12.phx.gbl... >>> How much data is being put in the cookies? I have heard of browser >>> limits on the size but not server-side limits. >>> >>> Could you use hidden form fields instead? >>> >>> -- >>> --Mark Schupp >>> >>> >>> "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message >>> news:uTISrs1SFHA.3184@TK2MSFTNGP14.phx.gbl... >>>>I have been trying to figure out why I am getting this message... I have >>>>an application that is 20 different ASP pages that works in sequential >>>>order (step1, step2, step3...). After each step the app writes the >>>>entered text to a cookie. This feature is so that if there is a >>>>problem, we can still retrieve the data. >>>> >>>> This Bad Request error has something to do with the cookie that is >>>> written to, because I can go all the way through the app to the last >>>> step (step20) and then it gives me a Bad Request. If I clear my >>>> cookies then it works fine, until step 20 again. >>>> >>>> Does anyone know what may be going on here? I am guessing that it has >>>> to do with the size of the cookie, but I am unsure how I can accomplish >>>> this task (allowing the entered data to be retrieved) without cookies. >>>> >>>> Thanks, >>>> Drew >>>> >>> >>> >> >> > >
I'm not familiar enough with cookies to help you much (the only cookie we use is the session cookie). Since you have a database available anyway why not keep the data in a table in the database? Then just keep a record identifier in the cookie. Your cookie retrieve/set code would turn into database select/update statements. Clear the temporary data when the final update is done. Have a cleanup job run occasionally to delete abandoned records. -- Mark Schupp [quoted text, click to view] "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message news:eUbVD5%23SFHA.2756@tk2msftngp13.phx.gbl... > I am actually inserting this data into a SQL Server database, but I wanted > to implement a "safety net", in case someone has some problems, then we can > cut and paste the data back into the app. > > My cookie code looks like this, > > Dim AllText > > If Request.Form("RelationshipsSocialization")<>"" Then > AllText = Request.Form("RelationshipsSocialization") > End If > > If Request.Form("Communications")<>"" Then > AllText = AllText & Request.Form("Communications") > End If > > Response.Cookies("ELPStep17")=AllText > Response.Cookies("ELPStep17").Expires= Now() + 10 > > The code fires on the page after the step, i.e. step17's data is put into a > cookie and inserted to the DB on step18.asp. > > Is it possible to create more than 1 cookie from a domain? My cookies now > look like this, > > dlaing@swvtc06[2].txt > > Thanks, > Drew > > "Mark Schupp" <notvalid@email.net> wrote in message > news:%234oGcE3SFHA.3464@tk2msftngp13.phx.gbl... > > Does the data have to persist past the last step (page 20)? > > > > If not, have each page include the data from the previous pages in hidden > > form fields. If so, a server-side database would be an option (just keep > > the user id in the cookie). > > > > Server-side script cannot write files to the client's system. You could > > use a component on the client-side to do so but that would require the > > user to grant permission. > > > > -- > > --Mark Schupp > > > > > > "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message > > news:eoEC7a2SFHA.1148@tk2msftngp13.phx.gbl... > >> The cookie I have on my computer (same error for me) is 13.2KB... > >> > >> There is a great deal of data going in there... What about using the FSO > >> to write to a file? Does FSO have the ability to write to a file on the > >> client computer? > >> > >> Thanks, > >> Drew > >> > >> > >> "Mark Schupp" <notvalid@email.net> wrote in message > >> news:OM5l$K2SFHA.2556@TK2MSFTNGP12.phx.gbl... > >>> How much data is being put in the cookies? I have heard of browser > >>> limits on the size but not server-side limits. > >>> > >>> Could you use hidden form fields instead? > >>> > >>> -- > >>> --Mark Schupp > >>> > >>> > >>> "Drew" <drew.laing@NOswvtc.dmhmrsas.virginia.SPMgov> wrote in message > >>> news:uTISrs1SFHA.3184@TK2MSFTNGP14.phx.gbl... > >>>>I have been trying to figure out why I am getting this message... I have > >>>>an application that is 20 different ASP pages that works in sequential > >>>>order (step1, step2, step3...). After each step the app writes the > >>>>entered text to a cookie. This feature is so that if there is a > >>>>problem, we can still retrieve the data. > >>>> > >>>> This Bad Request error has something to do with the cookie that is > >>>> written to, because I can go all the way through the app to the last > >>>> step (step20) and then it gives me a Bad Request. If I clear my > >>>> cookies then it works fine, until step 20 again. > >>>> > >>>> Does anyone know what may be going on here? I am guessing that it has > >>>> to do with the size of the cookie, but I am unsure how I can accomplish > >>>> this task (allowing the entered data to be retrieved) without cookies. > >>>> > >>>> Thanks, > >>>> Drew > >>>> > >>> > >>> > >> > >> > > > > > >
Don't see what you're looking for? Try a search.
|
|
|