Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #8074 > unrolled thread
| Started by | bill <william@TechServSys.com> |
|---|---|
| First post | 2013-01-12 11:44 -0500 |
| Last post | 2013-01-15 18:16 -0500 |
| Articles | 8 — 5 participants |
Back to article view | Back to comp.lang.php
POST data being truncated at " bill <william@TechServSys.com> - 2013-01-12 11:44 -0500
Re: POST data being truncated at " The Natural Philosopher <tnp@invalid.invalid> - 2013-01-12 17:02 +0000
Re: POST data being truncated at " bill <william@TechServSys.com> - 2013-01-13 05:32 -0500
Re: POST data being truncated at " Jerry Stuckle <jstucklex@attglobal.net> - 2013-01-12 16:27 -0500
Re: POST data being truncated at " bill <william@TechServSys.com> - 2013-01-13 05:31 -0500
Re: POST data being truncated at " "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2013-01-13 11:40 +0100
Re: POST data being truncated at " bill <william@TechServSys.com> - 2013-01-14 07:45 -0500
Re: POST data being truncated at " richard <noreply@example.com> - 2013-01-15 18:16 -0500
| From | bill <william@TechServSys.com> |
|---|---|
| Date | 2013-01-12 11:44 -0500 |
| Subject | POST data being truncated at " |
| Message-ID | <kcs3th$qk6$1@speranza.aioe.org> |
Script 1: I collect data, including a textarea - submitted via AJAX Script 2: I retrieve the data from the POST var and collate the data and create a human readable report which is put into a hidden field - submitted via AJAX Script 3: I retrieve the data from the POST var write the data to disk The data collected in form 1 has an embeded quote: "ok" which is passed via the POST array to form 2 without error. When the report (which contains the textarea containing the quote) passes from Script 2 to Script 3 the report is truncated just before the quote. Do I need to encode the report befoe putting it into a hidden form field ? or, anyone have any suggestions on how to debug this ? -bill
[toc] | [next] | [standalone]
| From | The Natural Philosopher <tnp@invalid.invalid> |
|---|---|
| Date | 2013-01-12 17:02 +0000 |
| Message-ID | <kcs4vo$ttt$1@news.albasani.net> |
| In reply to | #8074 |
On 12/01/13 16:44, bill wrote: > Script 1: I collect data, including a textarea - submitted via AJAX > Script 2: I retrieve the data from the POST var and collate the data and > create a human readable report which is put into a hidden field - > submitted via AJAX > Script 3: I retrieve the data from the POST var write the data to disk > > The data collected in form 1 has an embeded quote: "ok" which is passed > via the POST array to form 2 without error. > > When the report (which contains the textarea containing the quote) > passes from Script 2 to Script 3 the report is truncated just before the > quote. > > Do I need to encode the report befoe putting it into a hidden form field ? yes. there are a couple of commands to so this - I think htmlspecialchars will cover the case. > or, anyone have any suggestions on how to debug this ? > > -bill -- Ineptocracy (in-ep-toc’-ra-cy) – a system of government where the least capable to lead are elected by the least capable of producing, and where the members of society least likely to sustain themselves or succeed, are rewarded with goods and services paid for by the confiscated wealth of a diminishing number of producers.
[toc] | [prev] | [next] | [standalone]
| From | bill <william@TechServSys.com> |
|---|---|
| Date | 2013-01-13 05:32 -0500 |
| Message-ID | <kcu2gd$1cg$3@speranza.aioe.org> |
| In reply to | #8075 |
On 1/12/2013 12:02 PM, The Natural Philosopher wrote: > On 12/01/13 16:44, bill wrote: >> Script 1: I collect data, including a textarea - submitted via >> AJAX >> Script 2: I retrieve the data from the POST var and collate the >> data and >> create a human readable report which is put into a hidden field - >> submitted via AJAX >> Script 3: I retrieve the data from the POST var write the data >> to disk >> >> The data collected in form 1 has an embeded quote: "ok" which >> is passed >> via the POST array to form 2 without error. >> >> When the report (which contains the textarea containing the quote) >> passes from Script 2 to Script 3 the report is truncated just >> before the >> quote. >> >> Do I need to encode the report befoe putting it into a hidden >> form field ? > > yes. > there are a couple of commands to so this - I think > htmlspecialchars will cover the case. > Thanks NP -bill
[toc] | [prev] | [next] | [standalone]
| From | Jerry Stuckle <jstucklex@attglobal.net> |
|---|---|
| Date | 2013-01-12 16:27 -0500 |
| Message-ID | <kcskfr$681$1@dont-email.me> |
| In reply to | #8074 |
On 1/12/2013 11:44 AM, bill wrote: > Script 1: I collect data, including a textarea - submitted via AJAX > Script 2: I retrieve the data from the POST var and collate the data and > create a human readable report which is put into a hidden field - > submitted via AJAX > Script 3: I retrieve the data from the POST var write the data to disk > > The data collected in form 1 has an embeded quote: "ok" which is passed > via the POST array to form 2 without error. > > When the report (which contains the textarea containing the quote) > passes from Script 2 to Script 3 the report is truncated just before the > quote. > > Do I need to encode the report befoe putting it into a hidden form field ? > or, anyone have any suggestions on how to debug this ? > > -bill Yes, you do. But why are you passing it in a hidden field? Passing via the session is safer, more efficient and generally a better idea. -- ================== Remove the "x" from my email address Jerry Stuckle JDS Computer Training Corp. jstucklex@attglobal.net ==================
[toc] | [prev] | [next] | [standalone]
| From | bill <william@TechServSys.com> |
|---|---|
| Date | 2013-01-13 05:31 -0500 |
| Message-ID | <kcu2ev$1cg$1@speranza.aioe.org> |
| In reply to | #8076 |
On 1/12/2013 4:27 PM, Jerry Stuckle wrote: > On 1/12/2013 11:44 AM, bill wrote: >> Script 1: I collect data, including a textarea - submitted via >> AJAX >> Script 2: I retrieve the data from the POST var and collate the >> data and >> create a human readable report which is put into a hidden field - >> submitted via AJAX >> Script 3: I retrieve the data from the POST var write the data >> to disk >> >> The data collected in form 1 has an embeded quote: "ok" which >> is passed >> via the POST array to form 2 without error. >> >> When the report (which contains the textarea containing the quote) >> passes from Script 2 to Script 3 the report is truncated just >> before the >> quote. >> >> Do I need to encode the report befoe putting it into a hidden >> form field ? >> or, anyone have any suggestions on how to debug this ? >> >> -bill > > Yes, you do. But why are you passing it in a hidden field? > Passing via the session is safer, more efficient and generally a > better idea. > I can't think of one good reason. I just got in the habit of using the session for long term storage and POST for script to script communication. will re-think that. Thanks -bill
[toc] | [prev] | [next] | [standalone]
| From | "M. Strobel" <sorry_no_mail_here@nowhere.dee> |
|---|---|
| Date | 2013-01-13 11:40 +0100 |
| Message-ID | <alfh99F8e5cU1@mid.uni-berlin.de> |
| In reply to | #8077 |
Am 13.01.2013 11:31, schrieb bill: > On 1/12/2013 4:27 PM, Jerry Stuckle wrote: >> On 1/12/2013 11:44 AM, bill wrote: >>> Script 1: I collect data, including a textarea - submitted via >>> AJAX >>> Script 2: I retrieve the data from the POST var and collate the >>> data and >>> create a human readable report which is put into a hidden field - >>> submitted via AJAX >>> Script 3: I retrieve the data from the POST var write the data >>> to disk >>> >>> The data collected in form 1 has an embeded quote: "ok" which >>> is passed >>> via the POST array to form 2 without error. >>> >>> When the report (which contains the textarea containing the quote) >>> passes from Script 2 to Script 3 the report is truncated just >>> before the >>> quote. >>> >>> Do I need to encode the report befoe putting it into a hidden >>> form field ? >>> or, anyone have any suggestions on how to debug this ? >>> >>> -bill >> >> Yes, you do. But why are you passing it in a hidden field? >> Passing via the session is safer, more efficient and generally a >> better idea. >> > I can't think of one good reason. I just got in the habit of using the session for > long term storage and POST for script to script communication. What is long term? For me long term data is in the database. The session is good for data between requests, and it is secure i.e. the client can not manipulate it, and it is local to the server. /Str.
[toc] | [prev] | [next] | [standalone]
| From | bill <william@TechServSys.com> |
|---|---|
| Date | 2013-01-14 07:45 -0500 |
| Message-ID | <kd0umc$pkv$1@speranza.aioe.org> |
| In reply to | #8079 |
On 1/13/2013 5:40 AM, M. Strobel wrote: > Am 13.01.2013 11:31, schrieb bill: >> On 1/12/2013 4:27 PM, Jerry Stuckle wrote: >>> On 1/12/2013 11:44 AM, bill wrote: >>>> Script 1: I collect data, including a textarea - submitted via >>>> AJAX >>>> Script 2: I retrieve the data from the POST var and collate the >>>> data and >>>> create a human readable report which is put into a hidden field - >>>> submitted via AJAX >>>> Script 3: I retrieve the data from the POST var write the data >>>> to disk >>>> >>>> The data collected in form 1 has an embeded quote: "ok" which >>>> is passed >>>> via the POST array to form 2 without error. >>>> >>>> When the report (which contains the textarea containing the quote) >>>> passes from Script 2 to Script 3 the report is truncated just >>>> before the >>>> quote. >>>> >>>> Do I need to encode the report befoe putting it into a hidden >>>> form field ? >>>> or, anyone have any suggestions on how to debug this ? >>>> >>>> -bill >>> >>> Yes, you do. But why are you passing it in a hidden field? >>> Passing via the session is safer, more efficient and generally a >>> better idea. >>> >> I can't think of one good reason. I just got in the habit of using the session for >> long term storage and POST for script to script communication. > > What is long term? For me long term data is in the database. > > The session is good for data between requests, and it is secure i.e. the client can > not manipulate it, and it is local to the server. > > /Str. > For me "long-term" was for the user session, from login to logout. However, I have seen the light. I recoded using $_SESSION and all is well. bill
[toc] | [prev] | [next] | [standalone]
| From | richard <noreply@example.com> |
|---|---|
| Date | 2013-01-15 18:16 -0500 |
| Message-ID | <1q74l3weaw4bi.p00doflf6kwd$.dlg@40tude.net> |
| In reply to | #8074 |
On Sat, 12 Jan 2013 11:44:28 -0500, bill wrote: > Script 1: I collect data, including a textarea - submitted via AJAX > Script 2: I retrieve the data from the POST var and collate the > data and create a human readable report which is put into a > hidden field - submitted via AJAX > Script 3: I retrieve the data from the POST var write the data to > disk > > The data collected in form 1 has an embeded quote: "ok" which is > passed via the POST array to form 2 without error. > > When the report (which contains the textarea containing the > quote) passes from Script 2 to Script 3 the report is truncated > just before the quote. > > Do I need to encode the report befoe putting it into a hidden > form field ? > or, anyone have any suggestions on how to debug this ? > > -bill use "ok" or use 'ok' double quotes mark the beginning and end of a string.
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.php
csiph-web