14 Replies Latest reply: Jan 26, 2011 11:12 PM by redtopia RSS

    Did cf9 fix the issue with text getting cut off in cfdocument?

    idesdema Community Member

      See: http://kb2.adobe.com/cps/000/ea53f6ec.html

       

      I am displaying a query with cfdocument type="pdf" and it continues to cut text off at the end of the page.

       

      I assumed cf9 would have corrected this...

        • 1. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
          BKBK MVP

          Since it was already fixed in MX 7.x, I would imagine it fixed in CF 9.

          • 2. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
            idesdema Community Member

            1.JPG

             

            Me too.  However upon further inspection it appears to me that they did not.

             

            Here is my cfdocument tag...

             

            <cfdocument
            backgroundvisible="no"
            encryption="128-bit"
            format="pdf"
            fontembed="yes"
            marginbottom="1.2"
            marginleft="1.2"
            marginright="1.2"
            margintop="1.2"
            orientation="portrait"
            overwrite="yes"
            ownerpassword="password"
            pagetype="letter"
            permissions="AllowPrinting"
            unit="cm">
            <cfinclude template="template1.cfm">
            <cfdocumentitem type = "pagebreak"/>
            <cfinclude template="template2.cfm">
            </cfdocument>

            • 3. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
              Adam Cameron. Community Member

              The example code you cite is not much chop as far as a reproduction case goes, because the issue you're seeing is contingent on the contents of the include files, not the <cfdocument> tag itself.

               

              Can you create a simple, working, stand-alone example that demonstrates what you're seeing?

               

              --
              Adam

              • 4. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                idesdema Community Member

                Does the screenshot help at all? Bottom line is that text is cut when it goes from one page to the next. I tried to tinker with the margins and tried div tags wrapped around the text inside td but neither worked.

                • 5. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                  Adam Cameron. Community Member

                  Well... no, not really.

                   

                  I don't doubt you're seeing something you don't want to see, which is all the screen cap demonstrates.

                   

                  However there's no way of telling why you're seeing what you're seeing without you providing code to replicate it.  Plus if you provide code to replicate it requires you to actually write the code, which will quite possibly help you isolate what the problem is.

                   

                  I created a couple of include files with some lorem ipsum text in it and ran the code you posted.  It worked fine.  So... it's not intrinsically bung.  And also an attempt to replicate it with bare bones code did not replicate it, so the repro case needs to be a bit more thorough: it's something about what you're rendering in those include files.  You need to isolate what.

                   

                  As it stands there's no reason to think it's not something you're doing wrong (which is what it usually is when someone has problems, I'm sure you'd agree... I'm not being obtuse or rude when I say that).  I'd at least put equal money on that as I would on the bug still existing.

                   

                  --

                  Adam

                  • 6. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                    idesdema Community Member

                    No i agree. Its almost always something ive overlooked. Do you mind sending the code samples you tested? I want to test them on my server.

                    • 7. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                      Adam Cameron. Community Member

                      I literally just generated two sets of 15 paragraphs of lorem ipsum text and put them in template1.cfm and template2.cfm.

                       

                      http://www.lipsum.com/

                       

                      --

                      Adam

                      • 8. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                        idesdema Community Member

                        Can I please see a screenshot of where the text goes from one page to the next?  That's where I'm experiencing the text getting trimmed or sliced.

                        • 9. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                          Adam Cameron. Community Member

                          I'm not sure that me showing it to you working (which it does) really helps your cause.  I don't need to demonstrate to you that it works: you need to demonstrate to us (in a replicable fashion) that it doesn't work, then we can go about working out what you're doing to cause it to "not work".  Did my test not work for you when you tried it?  Or is it - as I suspect - you've not actually tried it?

                           

                          Have you done what I have suggested and tried to come up with a good reproduction case for this?  That would be the best usage of people's time here.

                           

                          But... here's the screen cap of it working fine on my machine:

                           

                          pdf_page_break_ok.png

                           

                          Now. Can we (read: "you" ;-) please focus on why it's not working for you, rather than why it is working for me.

                           

                          Come back to us with a good repro case...

                           

                          --

                          Adam

                          • 10. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                            idesdema Community Member

                            This is on a governement site so I can't have you see what it outputs (meaning give you a link) other than showing the screenshot.

                             

                            I did replicate your case.  As I suspect.

                             

                            The problem must be with formatting and/or styles.  I don't know.  Hence me originally posting.  Its hard to post here sometimes because it seems like I always run into some snide remark or attitude issue.

                             

                            Anyway, the main difference between the lorem ipsum example and what I'm doing is that its plain text versus tables with styles.

                             

                            The contents of my second include is something like...

                             

                                

                             

                             

                             

                            • 11. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                              Adam Cameron. Community Member

                              This is on a governement site so I can't have you see what it outputs (meaning give you a link) other than showing the screenshot.

                               

                               

                              That's fine.  I don't want to see your actual code based on live data: that will be full of irrelevant stuff which will just muddy the situation.

                               

                              Writing a repro case will actually involve some leg work on your part.  We've demonstrated it's not an intrinsic bug: the plain text version works fine.  So this means you need to start looking at what else is in those includes that might be impacting it.  I think you're on the right track thinking about the styles, and that's as good a place to start as any.

                               

                              So make another set of of files, stick the styles and some place holder content in it, and see if that breaks it.  If it doesn't... stick some other element in and see if that breaks it.  Continue until you can break it.  Then factor out stuff that probably doesn't seem to break it, and keep factoring stuff out so you have the bare minimum requirement to demonstrate the problem.

                               

                              You should be left with three small files:

                              1) the file with the <cfdocument> call;

                              2) the first include;

                              3) the second include.

                               

                              That's your repro case.  And, indeed, it's a general strategy for trying to solve a problem: identifying what the problem is.  By the time you do this, you will probably have worked out what the problem is by yourself, but if not, at least the rest of us have something to work with.

                               

                              Its hard to post here sometimes because it seems like I always run into some snide remark or attitude issue.

                               

                              Well I don't know if there's any snide remarks going on.  All I'm doing is asking you to throw us a bone.  You're asking for help - fine, that's what we're here for - but you're not actually acting on the advice given.  But you do seem to expect a solution withough working towards it.  How is that supposed to work?

                               

                              --

                              Adam

                              • 12. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                                idesdema Community Member

                                Hm.

                                 

                                I cannot even get the plain text version to work now.

                                 

                                Strange.  The contents of the second include (include_1449_p2_lines.cfm) is the lorem ipsum in plain text...

                                 

                                <cfdocument
                                format="pdf"
                                marginbottom="1"
                                marginleft="1"
                                marginright="1"
                                margintop="1"
                                overwrite="yes"
                                unit="cm">
                                <cfinclude template="includes/include_1449_p1_lines.cfm">
                                <cfdocumentitem type = "pagebreak"/>
                                <cfinclude template="includes/include_1449_p2_lines.cfm">
                                </cfdocument>

                                 

                                 

                                 

                                sample.JPG

                                • 13. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                                  Adam Cameron. Community Member

                                  Cool, we're getting somewhere.

                                   

                                  Can you clarify something... you say include_1449_p2_lines.cfm is the "lorem ipsum" stuff... what's in include_1449_p1_lines.cfm then?

                                   

                                  Is that page break being displayed there in your screen cap the one you're specifically putting in with <cfdocumentitem type = "pagebreak"/>, or is it just a soft break due to the length of the text?

                                   

                                  --

                                  Adam

                                  • 14. Re: Did cf9 fix the issue with text getting cut off in cfdocument?
                                    redtopia Community Member

                                    Why is this thread dead? As far as I can tell, this is still an open issue.

                                     

                                    Apparently cfdocument can't handle page breaks in the middle of tables. I'm having this same problem and I haven't found a work around, but I have found plenty of people who have had this problem.

                                     

                                    Please vote for this bug:

                                     

                                    http://cfbugs.adobe.com/cfbugreport/flexbugui/cfbugtracker/main.html#bugId=82761

                                     

                                    Or please let me know if there's a workaround.