Hi,

[I've added the mod_dtcl list to keep this information available for
everybody, hope you don't mind]

Thanks for your hint, since the only source of this problem are CGI
variables in my application (these are stored in ORACLE, but this seems not
to change 0D/0A values), your workaround helps:

instead of 
        set var [var get CGIvar]

I now use
        regsub -all "\r\n" "[var get CGIvar]" "\n" var


Thanks
Holger  
 ____________________________________________________________________
|
| Holger Zeinert   -   Development Manager CAE Division
|____________________________________________________________________
| LMS Deutschland GmbH      -      tel +49 631 30322-223, fax -166
| Luxemburger Str. 7, 67657 Kaiserslautern, GERMANY
| mailto:[EMAIL PROTECTED]     http://www.lmsintl.com




> -----Original Message-----
> From: Mark [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, April 08, 2003 2:36 AM
> To: Zeinert, Holger
> Subject: Re: Problem when passing multi-line text as FORM variables
> 
> 
> Not sure where to look for the original cause of this 
> problem, but I can
> tell you how I worked around it, plus some other issues at 
> the same time.
> In my apps the data coming from the user and from the 
> database engine were
> both passed through a "normalizing" proc that would do the following:
> 
> - replace all hex 0D0A with hex 0A
> - then ON A SEPARATE PASS replace all hex 0D with hex 0A
> 
> The effect is similar to the way Tcl normalizes newline 
> characters in file
> I/O channels, which is really helpful.  It simultaneously 
> solves another
> problem, which is that newline characters are often 
> non-standard when they
> come back from a database library (in my case TclODBC and/or 
> pgtcl).  Two
> calls to regsub can implement this algorithm.  Hope this helps.
> --
> Mark Hubbard: [EMAIL PROTECTED]
> Microsoft Certified Professional
> 
> "... where they have failed, you will succeed."
>                       - Morpheus
> 
> ----- Original Message -----
> From: "Zeinert, Holger" <[EMAIL PROTECTED]>
> To: <[email protected]>
> Sent: Monday, April 07, 2003 11:54 AM
> Subject: Problem when passing multi-line text as FORM variables
> 
> 
> > Hi,
> >
> > my problem is demonstrated in the following page "coding.ttml":
> >
> > <html>
> > <body>
> >
> > <form action=coding.ttml method=get>
> > <? puts -nonewline "<textarea cols=10 rows=5 name=text>[var get
> > text]</textarea>" ?>
> > <br>
> > <input type=submit value=check>
> >
> > </form>
> > </body>
> > </html>
> >
> > If I enter a<Return>b in the text area an press check, the 
> following URL
> is
> > created:
> >
> > http://localhost/coding.ttml?text=a%0D%0Ab
> >
> > When using mod_dtcl on Linux, this gets translated back to 
> the content of
> > the textarea as "a<Return>b", but running the server on 
> Windows, it's
> > displayed as "a<Return><Return>b", so both %0D and %0A are 
> considered to
> be
> > newlines. Repeating button "check" will double each 
> newline... annoying.
> >
> > BTW: coding a <Return> as %0D%0A is done with Mozilla on 
> Linux and using
> > Internet Explorer on Windows.
> >
> > Has anybody a clue where to check this?
> >
> > Best regards
> > Holger
> >  
> ____________________________________________________________________
> > |
> > | Holger Zeinert   -   Development Manager CAE Division
> > 
> |____________________________________________________________________
> > | LMS Deutschland GmbH      -      tel +49 631 30322-223, fax -166
> > | Luxemburger Str. 7, 67657 Kaiserslautern, GERMANY
> > | mailto:[EMAIL PROTECTED]     http://www.lmsintl.com
> >
> >
> >
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to