New line break and extra blank space characters disappear after submit form?

Hello,
I have a PDF form with a Submit button that is dynamically created in my code to send the form data to the server in HTML format.
After the form data is received on the server side, all strings with new line break and extra blank spaces are gone.
For example, if I enter string in a text field as shown below on the form:
Hello   ,  
this is  
    just a
test
After the form data is sent to the server, this string would become:
Hello , this is just a test
New line breaks are gone. Also, if there is more than 1 blank space character between 2 characters, the extra blank space characters would be removed as well.
It does not only happen to multi-line text field, even with single-line text field. If I have a string like this in a single-line text field:
Hello         this is just              a         test
After the form data is sent to the server, it would become:
Hello this is just a test
The form is created in OpenOffice then converted to PDF. The Submit button is created in my program using iText.  I have no idea it is iText that trims my string or PDF itself does it.
Can anyone give me any possible explanation? Thanks.

That is not what I get. Since it's URL-encoded, spaces are represented by the "+" character and carriage returns are represented by the "%0d%0a" (cr/lf) sequence.
Are you looking at the actual data that getting sent to the server or the output from the server after it processes it?

Similar Messages

  • Read Only TextAreas with Carriage Return, Line Breaks and Word Wrapping

    Hi all,
    I know there are a few posts around this subject but I cannot find the answer to the exact problem I have.
    I have a page that has a 'TextArea with Character Counter' (4000 Chars) that is conditionally read only based on the users credentials (using the 'Read Only' attributes of the TextArea item).
    When the field is editable (not Read Only) everything works fine but when I make the field Read Only I start to have problems:
    The first problem is that the Carriage Return and Line Breaks are ignored and the text becomes one continuos block. I have managed to fix this by adding pre and post element text of pre and /pre tags. This has made the Carriage Return and Line Breaks word nicely and dispaly correctly.
    However, it has introduced a second problem. Long lines, with no Carriage Returns or Line Breaks, now extend to the far right of the page with no word wrapping, making my page potentially 4000+ characters wide.
    How can I get the field to be display only, with recognised Carriage Returns and Line Breaks, and Word Wrapping inside a fixed width of, say, 150 characters?
    Many thanks,
    Martin

    Hi,
    Just a cut and paste of yours with the field name changed:
    htp.p('<script>');
    htp.p('$x("P3_COMMENTS").readonly=true;');
    htp.p('</script>');I also have the following in the page HTML Header, could they be conflicting?
    <script type="text/javascript" language="JavaScript">
    function setReleaseToProd(wpTypeCode){
       //setReleaseToProd($v(this))
      var get = new htmldb_Get(null,$v('pFlowId'),'APPLICATION_PROCESS=set_release_to_prod',0);
      get.addParam('x01',wpTypeCode);
      gReturn = get.get();
      if(gReturn) {
         $s('P3_RELEASE_TO_PROD',gReturn);
      get = null;
    </script>I am a long way from knowing much about Javascript (this page code was written by someone else) so all help is much appreciated.
    Martin

  • Extra blank space problem in af:selectOneChoice

    Hi All,
    I m using <af:selectOneChoice> to display few items in combo box. Now the problem is when the page gets load 1st time, its show an extra blank space in item list, but after selecting any item from the list page gets refreshed and reload again, now it does not have any extra blank space in the list.
    How do I remove this blank space from the combo box ???

    Hi Usha,
    1. Remove the Condition from you Context tab.
    2. In the Driver Program check for the condition and fill the value in the internal table which is passed to
        the adobe form.
    3. Make the subform (under which the field is added in the hierarchy view) as flowed.
    4. In the script editor, Select the 'javascript' and write the script to hide the form field specifying the condition here.
    for e.g
    if (xfa.form.FORM.SUB_FORM.matnr == "123") {
        xfa.form.FORM.SUB_FORM.Region = "hidden";
    NOTE: Javascript is Case sensitive and stops working immediately after the line of code where an error occurs.
    Hope this proves to be useful.
    Thanks,
    Swar.

  • Forced Line Break and Paragraph Return

    Hi.. It´s maybe a simple question but I cannot see diferences.
    What´s the difference between Forced Line Break and Paragraph Return ?
    Thank's for the answer

    A force line break is still the same paragraph. You won't see a difference unless there is some text change with each new paragraph, such as a style change or the addition of space before or after a paragraph. The forced line break can also be used as a trigger in a nested style to make the first line or lines formatting for a paragraph different from the following lines.
    Peter

  • Pressing Enter inserts new line break instead of "executing" command

    I have noticed a rather strange behavior on my new TPT2. This occurs ONLY when I am using the Windows 8 touch keyboard in the "Metro" environment.
    Whenever I press the Enter key on said keyboard (for example when sending an instant message on Skype), the keyboard inserts a new line in the text box instead of acting like a "normal" Enter key and execute the default command (send the message in this example).
    I have connected an external keyboard and this problem does not show up. Everything works as expected. I also brought up the regular on-screen keyboard (launched from the Ease of Access menu) and it works the way it should. The problem is only with the Metro touch keyboard.
    It seems that for some reason, the Metro touch keyboard interprets the Enter key pressing as "insert a line break".
    Does anyone know how to fix this? It is extremely annoying.

    Just checked that, you are right, Photoshop doesn't recognize Shift-Enter as a line break and treat it as a Return which is a problem with paragraph formatting. Obviously a bug.
    Good news workaround is that it recognizes the line break character if you paste it from another program like Microsoft Word. If you don't have a program that allows you to copy just that character and use paste instead of Shift-Return, you have to type your entire text in some other program and copy paste to Photoshop.

  • How to add extra blank space in xml

    I open the xml file in notepad I get this
    <XXON_EXT_BANK_ACCOUNT_NAME>創名聯合會計師事務所                                        </XXON_EXT_BANK_ACCOUNT_NAME>
    But when I open the xml file in html format the blank space is gone.
    How can I add extra blank space in xml?

    Hi
    Why do you need the extra space for?
    This difference in display that you see between your browser and notepad/notepad++
    will not affect your generated report.
    Bogdan 

  • I bought the student and teacher version of CS5 extended for windows. Can I download the Mac version to my new  apple computer  and use the same serial number after removing phtoshop from my PC?

    i bought the student and teacher version of CS5 extended for windows. Can I download the Mac version to my new  apple computer  and use the same serial number after removing phtoshop from my PC?

    Can I download the Mac version to my new  apple computer  and use the same serial number after removing phtoshop from my PC?
    Short answer: not for CS5.
    Platform swaps are available but only for CS6
    Order product | Platform, language swap

  • WiFi Breaking and getting slow in MacBook Pro after upgrading to OS X Yosemite

    WiFi Breaking and getting slow in MacBook Pro after upgrading to OS X Yosemite

    WiFi Breaking and getting slow in MacBook Pro after upgrading to OS X Yosemite

  • TS1424 Can't download, buy or even update apps / A message advising a new Itunes terms and conditions is coming up even after my agree and acceptance... Is there a problem in Itunes? same problem with deferent devises

    A message advising a new Itunes terms and conditions is pop up even after my agree and acceptance... Is there a problem in Itunes? same problem with deferent devices
    Just Can't download, buy or even update apps...

    I use only one Apple ID and only one ID. I did have to change the password at one point but I had no issues at all with updating apps after I changed the password.
    If you can download new apps with the ID that you changed the password for, I would think that you will be able to update apps associated with that ID as well.
    Did you try restarting the iPad after signing out of the one account and then sign in to the other account/accounts?

  • New line character and carriage return in XML, please help, thanks

    In XML, "&#10;" is only the new line character. I have tried that. If you put that in your XML, for example:
    <tag>line1&#10;line2&#10;line3</tag>
    You will get the output as follow:
    line1
    ____line2
    ________line3
    (where ___ represents space)
    The output that I want is actually like:
    line1
    line2
    line3
    So I would like to ask how I can do this.
    Thanks,
    Jackie

    while parsing your XML file you can directly suppress these newline and similar things in characters() method of SAX parser.
    you can opt to do nothing when you encounter them else if it is normal character then use it to print it.

  • Page Break-An extra blank page as the last page.

    I have a template with a page break (<?split-by-page-break:?>) at the end of the template prior to the end of loop <?end for-each?>. This is causing an extra blank page at the end everytime the report is run. I checked this forum and got some pointers and used couple of them but didn't get the blank page to go!
    I tried this in my page break filed! <?if:position()!=last()?><?split-by-page-break:?><?end if?>
    Please help.
    Thanks,
    Fran

    Hi, ive faced a similar problem in the past, I worked around it using subtemplates, but it still gives out an extra blank page if the content on the last page comes within 3 lines of the bottom of the page.. otherwise its ok..if you could send me your template and a sample xml file at domnic26ATgmail, i will see what i can do to help.
    regards,
    Domnic

  • Line breaks and wrapping incorrect on hebrew+english text

    i have a string of mixed text with hebrew and english, usually the english is only the last word in the string.
    when trying to show on a limited space (110px more or less) the line break looks like it performs incorrectly since the string is all mixed and it shows the english word in between the hebrew words.
    I'm using the following, in a *pure* as3 project in the flex ide using sdk 3.5 and last version textframework swc.
    private function addText():void{
         //title is a string brought from xml.
         title = "Canazei סקי איטלקי במיטבו בעיירה";
         var titleLine:StringTextLineFactory = new StringTextLineFactory();
         titleLine.text = title;
         titleLine.paragraphFormat
         titleLine.compositionBounds = new Rectangle(0,0,120,120);
         titleLine.spanFormat = formatMe(blue, 12, "bold");
         titleLine.createTextLines(callbackTitle);
         function callbackTitle(tl:TextLine):void{
              addChild(tl);
              tl.y = 12;
              tl.x = 109 - tl.width;
    //thats the formatMe function:
    public function formatMe(colour:uint, size:uint, weight:String):TextLayoutFormat{
         characterFormat = new TextLayoutFormat();
         characterFormat.fontSize = size;
         characterFormat.color = colour;
         characterFormat.direction = flashx.textLayout.formats.Direction.LTR;
         characterFormat.textAlign = flashx.textLayout.formats.TextAlign.START;
         characterFormat.fontFamily = "Arial, Helvetica, _sans";
         characterFormat.lineHeight = "100%";
         if (weight == "bold"){
              characterFormat.fontWeight = flash.text.engine.FontWeight.BOLD;
         return characterFormat;
    any help with this will be greatly appreciated, unfortunately the bidi support is not clear and sometimes the examples in the docs are not working.

    I played around with your example a little, and removed the explicit line placement you added, and have this (see below). It works as expected if you consider English the dominant language. If you wanted it to assume Hebrew instead, you should set the direction to RTL instead of LTR. Please let me know if this works for you.
    Thanks!
    package
        import flashx.textLayout.elements.TextFlow;
        import flashx.textLayout.factory.StringTextLineFactory;
        import flashx.textLayout.formats.TextLayoutFormat;
        import flash.geom.Rectangle;
        import flash.display.Sprite;
        import flash.text.engine.TextLine;
        public class TCMTestFocus extends Sprite
            public function TCMTestFocus():void{
                //title is a string brought from xml.           
                                                var    title:String = "Canazei סקי איטלקי במיטבו בעיירה";
                var titleLine:StringTextLineFactory = new StringTextLineFactory();           
                titleLine.text = title;
                titleLine.paragraphFormat
                titleLine.compositionBounds = new Rectangle(0,0,120,120);
                titleLine.spanFormat = formatMe(0x0000FF, 12, "bold");
                titleLine.createTextLines(callbackTitle);
                function callbackTitle(tl:TextLine):void{
                    addChild(tl);               
            //        tl.y = 12;               
            //        tl.x = 109 - tl.width;
        public function formatMe(colour:uint, size:uint, weight:String):TextLayoutFormat{
                var characterFormat:TextLayoutFormat = new TextLayoutFormat();           
                characterFormat.fontSize = size;
                characterFormat.color = colour;
                characterFormat.direction = flashx.textLayout.formats.Direction.LTR;
                characterFormat.textAlign = flashx.textLayout.formats.TextAlign.START;
                characterFormat.fontFamily = "Arial, Helvetica, _sans";
                characterFormat.lineHeight = "100%";
                if (weight == "bold"){
                    characterFormat.fontWeight = flash.text.engine.FontWeight.BOLD;
                return characterFormat;

  • Line Breaks and Preferred Carrier Text

    I support our E-Commerce (ISA 5.0) web application. We are using the R/3 edition, which in our case is an ECC6 backend (not CRM).
    Anyhow, I am pulling the customer preferred carrier text from the vendor master into the web application. Once I have it, I am appending additional text (ex, "Qualifies for FREE FREIGHT") to it, then sending it back to ECC6 when the order is send/saved.
    To set the text I'm using the following line of code....
    ui.header.setText(new Text("100", appText));
    with appText = "FREE FREIGHT" + "\r\n" + preferredCarrierTextFromR3;
    Here is my problem. Last year, when our backend was R/3 6.40c, this worked fine. This year, however, the "\r\n" are being 'translated' as garbage characters (# signs), and thus ignored. So, when this modified preferred carrier text is printed to a Pick List, for example, the text is overwriting. You can actually see # signs printed where last year a line break would occur, and thus, the preferred carrier text is printing directly on top of the "FREE FREIGHT" text.
    I've tried everything I could Google as a replacement for "\r\n", but I have yet to find a solution to the problem. I've tried string buffer, line.separator, chr(10), chr(13) and just about any other suggestion I could find.
    I should add that I'm not really sure what is causing the line break characters to not be recongnized correctly.
    Anyone have any ideas?
    I appreciate any and all feedback.
    Thank you,
    Bryan
    Edited by: Bryan Fickle on Feb 21, 2008 11:04 AM

    I support our E-Commerce (ISA 5.0) web application. We are using the R/3 edition, which in our case is an ECC6 backend (not CRM).
    Anyhow, I am pulling the customer preferred carrier text from the vendor master into the web application. Once I have it, I am appending additional text (ex, "Qualifies for FREE FREIGHT") to it, then sending it back to ECC6 when the order is send/saved.
    To set the text I'm using the following line of code....
    ui.header.setText(new Text("100", appText));
    with appText = "FREE FREIGHT" + "\r\n" + preferredCarrierTextFromR3;
    Here is my problem. Last year, when our backend was R/3 6.40c, this worked fine. This year, however, the "\r\n" are being 'translated' as garbage characters (# signs), and thus ignored. So, when this modified preferred carrier text is printed to a Pick List, for example, the text is overwriting. You can actually see # signs printed where last year a line break would occur, and thus, the preferred carrier text is printing directly on top of the "FREE FREIGHT" text.
    I've tried everything I could Google as a replacement for "\r\n", but I have yet to find a solution to the problem. I've tried string buffer, line.separator, chr(10), chr(13) and just about any other suggestion I could find.
    I should add that I'm not really sure what is causing the line break characters to not be recongnized correctly.
    Anyone have any ideas?
    I appreciate any and all feedback.
    Thank you,
    Bryan
    Edited by: Bryan Fickle on Feb 21, 2008 11:04 AM

  • How to insert new line break in XSLT mapping

    Hi experts,
    I am doing file to mail scenario, i am sending the text file as an attachment using reciever mail adapter.
    I did everything, i can able to send the mail with text file attachment, but with in the file i got multiple rows, i need to put line break in XSLT mapping.
    I did use following statement but it is inserting small rectangle between the records, the records are not separating with new lines, all are in one line.
    <xsl:text>*#xA;</xsl:text>   
    note: in real coding replace * with &
    Can anyone suggest me how to insert new line in XSLT mapping.
    My XSLT mapping as look like:
    <?xml version='1.0'?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:ns0="http://www.Coj.co.za/SapIsuToABSA/DirectDebitFile">
    <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>
    <xsl:variable name="break">&lt;br/&gt;</xsl:variable>
    <xsl:variable name="space"> </xsl:variable>
    <xsl:variable name="newline"><xsl:text></xsl:text></xsl:variable>
    <xsl:template match="/">
    <ns1:Mail xmlns:ns1="http://sap.com/xi/XI/Mail/30">
    <Subject>Please Check Attached Direct Debit File</Subject>
    <From>S@za</From>
    <To>P@za</To>
    <Content_Type>text/plain</Content_Type>
    <Content>
    <xsl:for-each select="MT_SapIsuToABSA_DirectDebitFile/DirectDebitRec/Body">
    <xsl:value-of select="Space1"/>
    <xsl:value-of select="Cust_AccNo"/>
    <xsl:value-of select="Reserve_1"/>
    <xsl:value-of select="Cust_Name"/>
    <xsl:value-of select="Cust_Name1"/>
    <xsl:value-of select="Cust_Bank_AccNo"/>
    <xsl:value-of select="Space2"/>
    <xsl:value-of select="Cust_Bank_BranchNo"/>
    <xsl:value-of select="Reserve_2"/>
    <xsl:value-of select="Space3"/>
    <xsl:value-of select="Cust_AccNo_1"/>
    <xsl:value-of select="Space4"/>
    <xsl:value-of select="Reserve_3"/>
    <xsl:value-of select="Deduction_Amnt"/>
    <xsl:value-of select="Space5"/>
    <xsl:value-of select="Reserve_4"/>
    <xsl:value-of select="Space6"/>
    <xsl:value-of select="Action_Date"/>
    <xsl:value-of select="Space7"/>
    <xsl:value-of select="Reserve_5"/>
    <xsl:text>*#xA;</xsl:text>   
    note: in real coding replace * with &
    </xsl:for-each>
    </Content>
      </ns1:Mail>
      </xsl:template>
      </xsl:stylesheet>
    Kind regards,
    Praveen

    Hi,
    I think <xsl:text>#xa;</xsl:text> should do the trick, but depending on which OS (ux or win), the "new line" chars sequence is different (win would require a CRLF like <xsl:text>#xd;*#xa;</xsl:text>)
    Chris
    -> &
    Edited by: Christophe PFERTZEL on Apr 14, 2010 2:16 PM

  • Subreport causing an extra blank space in PDF export of SSRS 2008 report

    Hi All,
    I have a requirement of showing individual report and a Supervisor report.
    In the individual report, I will run the SSRS report for a particular worker. In the supervisor report, I am supposed to show the report for each worker working under the supervisor.
    I have created the individual report and it works fine(even when exported to PDF).
    Now in order to create the supervisor report, I will get the supervisor ID which I broke into various individual ID's of workers working under the supervisor in DataSet and created a subreport which points to the Individual report. I embedded this subreport
    in a Tablix and gave a group by on the ID so that for each ID, the report runs one time.
    The issue that I am facing is that when I export the Supervisor report in PDF, after each page, I get an extra blank page.
    The Supervisor report only contains the Tablix which has only one column containing the sbureport which points to the Individual report and a Header and footer and nothing else.
    Still I am getting this extra page on PDF export. Please help on the same.

    Hi HiddenIdentity,
    According to your description, you have a report to display subreport for each ID and you have set page break between each group instance. Now when you export the report into PDF, it generate an extra blank page between each group instance. Right?
    In Reporting Services, Reports exported using PDF and Image are optimized for a book-like or printed experience where pages are a consistent size. Page breaks are inserted vertically and horizontally at specific locations within the report body. These specific
    locations are determined by the page width and page height settings. Please see the following link:
    Rendering Behaviors (Report Builder and SSRS)
    In this scenario, when you put a sub report in a cell, the whole subreport body will be displayed in this cell. If the total width exceed the page width of a PDF page, the content will goes to the next page. That's it need two pages to render each subreport.
    So please modify the subreport report size to make it as big as the tablix so that it can be rendered within one PDF page.
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou

Maybe you are looking for

  • Itunes will not Install - Help needed!

    I recently uninstalled and deleted my old version of itunes as it was acting up.However when i went to download the new version it always stops at the stopping services part it says i do not have sufficient privaleges.Please help.

  • How to attached OLM core form in other button (Enter& Maintain form)

    Dear All, i want to attached OLM core form in Enter & Maintain "Other Button". Please give me detail on urgent basis. Thanks MBS-HRMS

  • Prints too dark

    I'm using the C309g-m printer.  I'm using an HP w2338h monitor calibrated with a Spider 2 Pro colorimiter. I'm printing to HP advanced paper I've tried printing to Ilford Galerie smooth pearl paper I use the adobe 1998rgb color space in my editing. I

  • Access 2013 - I can't export files to dBaseIV

    Hi, Access 2013 - I can't export files to sBaseIV, and i need this for mi job. Can you help me please? Thanks, Regards

  • My iphone has troubles with on/off bottom

    Tengo el problema que mi iphone 5 se descargo y cuando quise volverlo a cargar no funciono mas, creo que es algo de ese programa de los iphone defectuosos, pero ya registro mi numero imei y no me funciona que puedo hacer soy de Ecuador necesito su ay