Copy link to clipboard
Copied
This is my code:
<cfhtmltopdf orientation="landscape">
<h3>Test Landscape Output</h3>
</cfhtmltopdf>
This is my output:
Copy link to clipboard
Copied
Do you mean that you no longer have problems with cfhtmltopdf?
Copy link to clipboard
Copied
no, not what I meant. I can run the tag, but all output is portrait.
Copy link to clipboard
Copied
@dwaynea8754223 wrote:
no, not what I meant. I can run the tag, but all output is portrait.
That is strange. Like you, I am on ColdFusion 2023 Update 11. When I copy and run your last code, I get the expected result (a PDF in landscape format - attached).
Copy link to clipboard
Copied
Further thoughts:
Copy link to clipboard
Copied
I have pretty much the same problem that Dwayne has on one of my servers. After Update 11, clear felix cache and restart both CF service and cf addon service, it still only generates in portrait using cfhtmltopdf. Our staging server works perfectly fine and I did not need to clear the felix cache on that server. I just updated to update 11 in the cfadmin and boom, it worked on staging. But our production doesn't generate in landscape; only portrait.
I even had the same issue with error adding PDF service manager and then restarted and it came back.
I've compared the update version and htmltopdf package version between both servers and they are identical. Both using same version JVM. I can't make any sense to why it works on one server but not the other.
Copy link to clipboard
Copied
I even had the same issue with error adding PDF service manager and then restarted and it came back.
By @Stellar_day16E5
You should have updated the existing PDF Service Manager, instead of adding a new PDF Service Manager. See my previous post. An attempt to add a new service manager might result in settings that differ between the servers.
Copy link to clipboard
Copied
That's what I did the first time. Clicked the Edit icon next to the PDF service and the form populated with the details. Then clicked Update and instead of updating, it removed the PDF service altogether.
So then I clicked Add an added it back, however, it gave the Error adding PDF Service. I tried 3-4 times to add it. Finally, just restarted CF and the service was there again. But still only doing portrait not landscape.
Copy link to clipboard
Copied
I got a patch for this by email from Adobe on Thursday. I haven't installed it. I will asap and let ya'll know how it goes. hf202300-4224136
Copy link to clipboard
Copied
Hi,
Did you ever install the patch Adobe gave you and did it fix the issue?
-Steve
Copy link to clipboard
Copied
I had the same exact problem and it sounds like you installed through add-on services too
Copy link to clipboard
Copied
Our hosting provider installed CF, so I'm not sure what steps they followed during install.
Copy link to clipboard
Copied
Then clicked Update and instead of updating, it removed the PDF service altogether.
By @Stellar_day16E5
Removing the last PDF Service Manager? That points to a serious problem right there. I expect ColdFusion to hang on to at least one PDF Service Manager, and to prevent you from deleting the last one.
Those retries you did might have upset the settings. I would therefore suggest a reset of the PDF engine.
Try the following steps and see if they help:
<cfhtmltopdf orientation="landscape">
<h3>Test Landscape Output</h3>
</cfhtmltopdf>​Copy link to clipboard
Copied
Hello Steve,
We have fix for this issue, please send an Email to cfinstall@adobe.com
Thanks & Regards
Ravi
Copy link to clipboard
Copied
We have fix for this issue, please send an Email to cfinstall@adobe.com
By @Ravi Shankar266617537wjh
Thanks for the fix, @Ravi Shankar266617537wjh and Team.
Copy link to clipboard
Copied
I am having this problem and emailed cfinstall@adobe.com and got a bounce back that the email address does not exist.
Copy link to clipboard
Copied
Copy link to clipboard
Copied
@Stellar_day16E5 , try cfinstal@adobe.com (with one 'L')
Copy link to clipboard
Copied
REan across this thread due to having the same issue. I actually logged in to say "ME TOO!", essentially. And then I solved it while cleaning up to attach an example. Try this:
<cfhtmltopdf
destination = "generated.pdf"
pagetype="custom"
pagewidth="11" pageheight="8.5"
overwrite="true" orientation="landscape"
margintop=".25" marginbottom=".25" marginleft=".25" marginright=".25">
<cfoutput>WOOT!</cfoutput>
</cfhtmltopdf>
The line that made ALL the difference (nothing else really did it), was the pagetype="custom". If I take that out, I'm back to portrait. However, you have to have pageheight/pagewidth, as "custom" requires it.
Copy link to clipboard
Copied
Will, thanks for sharing the workaround.
As for others who may consider it, can you clarify if you had or had not gotten the fix jar Adobe offered above? And what cf version are you on, and what update applied? Finally, is your cf add-on service installed separately from cf?
Sorry for the barrage of questions, and feel free to say you "don't know" for any. I merely ask in case you DO know 🙂 , again for the sake of others (who may prefer not to make code changes).
Copy link to clipboard
Copied
I can provide SOME of the info... I'm using Commandbox, for starters. However, I'm only using it because that's what I always use locally. Typically I'm using Lucee for my "scratch" (test) site and my own stuff. For work, though, it's ACF, so I switched the engine for today's PDF work. So... on Commandbox, I grabbed these snippets of info, hopefully what you're looking for:
- adobe-2023.0.12.330713
- document:2023.0.08.330668
- image:2023.0.11.330706
- pdf:2023.0.11.330706
- htmltopdf-2023.0.11.330706
I will be testing, at some point, on a full and "normal" CF 2023 installation. Probably tomorrow or the next day and can report back as to whether it worked correctly or not. I suspect it will.
Copy link to clipboard
Copied
Thanks for the clarification. So update 12 of cf 2023 is indeed the current latest. And it sounds like you'd not tried the hotfix jar Adobe offered. OK.
As for running cf on Commandbox, you're not at all alone, of course. But that can indeed be quite different with respect to some matters, especially when it comes to where the cf add-on service is implemented. (That's what processes cfhtmltopdf, and the "pdf service" definition in the cf admin points to its port.)
In a traditional cf deployment, that add-on service a separate process (running in fact on jetty rather than tomcat, like cf does--and as you may know, Commandbox implements cf atop undertow. I just don't know how it may implement the add-on service. Maybe someone familiar will chime in.)
But let's see how your efforts go tomorrow. If you'll be installing cf, note that it's during that install you'll be asked if you want to install the add on service, and one of its options will be "pdfg", which is the name for the specific Java web app that does that processing of cfhtmltopdf, which would be implemented within the add on service. It can get confusing! 🙂
Anyway saying yes would cause that add on service to be implemented in the cf folder and running atop jetty.
Some others in this thread said no to that (or whoever installed cf previously did), and so when they later wanted to use cfhtmltopdf (and had no add on service anywhere to point to), they then installed the add on service via a separate installer that Adobe offers on their site...so, lots of variety in deployment possibilities. (Heck, one can also implement both cf and the add on service in containers that Adobe offers, and Commandbox offer their own cf container. But let's not muddy the waters any further, until necessary.)
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Well, my first reply thanked you for that workaround. I meant that sincerely.
The rest of my replies today have been for the sake of those who may prefer not to make code changes, and for your sake in saying you'd be installing cf.
It's a lot to consider, sure.. And I ended my first reply saying I'd understand if you didn't want to go down this rabbit hole of considering configuration matters.
Copy link to clipboard
Copied
Get ready! An upgraded Adobe Community experience is coming in January.
Learn more