Bug #81169 - Div bkgrnd color (of 1st div w/ content) not honored if cfdocument/pdf written to disk

Bug for: Div background color (of 1st div w/ content) is not honored when cfdocument/pdf is written directly to disk.
==================
Steps to reproduce
==================
Run the following code with (and without) the cfdocument 'name' attribute.  Then compare both PDFs (the PDF written directly to browser, and the PDF written directly to disk)
<cfdocument format="pdf" name="myPDF">
<div style="background-color:#1a9cee;"></div>
<div style="background-color:#1a9cee; border:2px solid #1a9cee;">I am the 1st div w/ content. Background color is only honored when PDF is written to browser. When PDF is written to disk, background color is near black.</div>
<div style="background-color:#1a9cee; border:2px solid #1a9cee;">I am the 2nd div w/ content. Background color is always honored.</div>
</cfdocument>
<cfif structKeyExists(variables, "myPDF")>
  <cfpdf action="write" source="variables.myPDF" destination="#expandPath('./MyPDF.pdf')#" overwrite="yes" />
</cfif>
==================
Attachments
==================
PDF written directly to disk: 20091214_Bug_81169_CFDocumentPDFDivBkgrndColorNotHonored_01.pdf
PDF written directly to browser: 20091214_Bug_81169_CFDocumentPDFDivBkgrndColorNotHonored_02.pdf
Thanks!,
-Aaron Neff
Btw, this bug is new to CF9.  This bug did not affect CF 8.0.1.

Ok, if anyone else is experiencing this same issue, here is a workaround.  The issue is that when a cfdocument-generated PDF is written directly to disk, then the background color of the 1st non-empty block-display HTML element is ignored (unless there is an inline-display HTML element preceding it).  Instead, the background color is near-black.
So, the workaround is to simply ensure an inline-display HTML element preceds the problematic block-display HTML element.  (a <span></span> will do the trick)
Here was the original code.  Note that line #3 is the 1st non-empty HTML element, and that it is a div (block-display), and it has a background color.  If the PDF is written to disk, then the specified background color is ignored.  Instead, the background color is near-black.  Again, this does not occur when the PDF is written directly to browser.
1| <cfdocument format="pdf" name="myPDF">
2| <div style="background-color:#1a9cee;"></div>
3| <div style="background-color:#1a9cee; border:2px solid #1a9cee;">I am the 1st non-empty block-display HTML element. Background color is only honored when PDF is written to browser. When PDF is written to disk, background color is near black (unless preceded by an inline-display HTML element).</div>
4| <div style="background-color:#1a9cee; border:2px solid #1a9cee;">I am the 2nd div w/ content. Background color is always honored.</div>
5| </cfdocument>
6| <cfif structKeyExists(variables, "myPDF")>
7|   <cfpdf action="write" source="variables.myPDF" destination="#expandPath('./MyPDF.pdf')#" overwrite="yes" />
8| </cfif>
Here is the 'fixed' code (note that "display:inline" has been added to line #2):
1| <cfdocument format="pdf" name="myPDF">
2| <div style="background-color:#1a9cee; display:inline;"></div>
3| <div style="background-color:#1a9cee; border:2px solid #1a9cee;">I am the 1st non-empty block-display HTML element. Background color is only honored when PDF is written to browser. When PDF is written to disk, background color is near black (unless preceded by an inline-display HTML element).</div>
4| <div style="background-color:#1a9cee; border:2px solid #1a9cee;">I am the 2nd div w/ content. Background color is always honored.</div>
5| </cfdocument>
6| <cfif structKeyExists(variables, "myPDF")>
7|   <cfpdf action="write" source="variables.myPDF" destination="#expandPath('./MyPDF.pdf')#" overwrite="yes" />
8| </cfif>
magical

Similar Messages

  • Div header tag - not displaying correctly

    I thought I had resolved an issue with a div header tag, but - as per a reply in my 'text as gif' thread, possibly not!
    The header contains three images; a logo, a banner (text), and a picture of a castle.  These should display in a  line.
    When I first set it up, I realised that the castle picture was normally ending up below the other two on smaller screens etc. 
    So I changed the dims for my div container from min 760px/max 1260px, to a set width (960px).  I then rejigged the three images so the widths were within 960px, with some to spare for the spacing (total widths of the three are 900: hspacing another 20 pixels).  There is no padding/borders defined.  Therefore the total should be well within the 960 width (?).
    It looks fine on my PC (widescreen); in 3 browsers, using the restore down menu command (ie to make it not full screen), and by  using the Dreamweaver multiscreen preview (phone, tablet, smaller desktop).  It wasn't ideal (as scrolling required), but at least meant the header (and the rest of the screen) displayed correctly, ie in a horizontal line (and then sidebar - content - sidebar).
    If I set my container width much smaller, most of the screen will be green (the body) in big screens.
    If I rejig the dimensions, it's all a bit hit and miss (and why don't the current dimensions work?).
    Do I need to define the width of the header (as well as the container)?
    Help!  Thank you
    http://hertfordcarnival.org.uk/dev/Index.html

    Hi there, I started off using one big image, but it didn't look right with regards to size and placing (ie I wanted the logo on the left edge, the castle on the right edge, etc). When you say slice, what do you mean?  One image in from fireworks, and then ... ? Thanks again
    Date: Wed, 7 Dec 2011 01:37:10 -0700
    From: [email protected]
    To: [email protected]
    Subject: Div header tag - not displaying correctly
        Re: Div header tag - not displaying correctly
        created by osgood_ in Dreamweaver - View the full discussion
    Datafan55 wrote: I thought I had resolved an issue with a div header tag, but - as per a reply in my 'text as gif' thread, possibly not!  Why not just use one big image  then you wont have a problem of with the alignment. Certainly don't use 'vspace' and 'hspace' to position the images. If you want to use 3 seperate images start by setting them us as one complete image then slice it into 3 images. Then use the following css to position the images side by side. #header img If the total sum of the width of the images is the same or does not exceed 960px then the images should be in a nice row side by side. They will actually sit side by side without using 'float' but you'll get a small gap between them which will be added to the sum of the width which will exceed 960px causing the third image to drop onto the next line.
         Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/4068499#4068499
         To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/4068499#4068499. In the Actions box on the right, click the Stop Email Notifications link.
         Start a new discussion in Dreamweaver by email or at Adobe Forums
      For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.

  • Illustrator CS6, CC, "CC 2014" not honoring a 100% Cyan Spot Color Swatch change.

    Why does Illustrator CS6, CC, "CC 2014" not honor a "100% Cyan Spot Color Swatch" changing the % value in the Color Pallet.
    I create 3 different Spot Color Swatches of 100% Cyan, 100% Magenta and 100% Yellow in the Swatch pallet.
    Then I fill 3 different squares with one of each Swatch and put the Fill to 70% on all in the Color Pallet.
    Now I try to change each square back to 100% value in the Color Pallet by typing a number into the Percent Field.
    But the Cyan Spot Color does not honor the entry, the Yellow and Magenta are fine.
    Has anyone seen this behavior before, and what can be done to resolve it?
    Thanks,
    J

    I would report this as a bug, you can use the slider to set it to 100%, but not enter that value by  typing. Strange.
    Adobe - Feature Request/Bug Report Form

  • 1st Generation iPod (5GB) not working with new iMac

    Hi,
    i have the Problem, that my 1st generation iPod is not detected by my new imac (20'' 2,4 Ghz). When i plug in the firewire cable, nothing happens. DiscUtility sees no disc at all.
    But when i plug in the iPod "behind" another Firewire disc (acting as a fw-hub), the iPod ist detected within a second, and everything works fine.
    I just wanted to know if someone else is having this Problem, or if someone else has a working iPod 1.Gen on the new iMac.
    Thanks
    Joerg

    Hi JvdL,
    I am one with a 1st gen iPod (Windows, 10GB).
    But I have no problems with it and I also don't have a last gen. iMac.
    However, in the iPod Forum http://discussions.apple.com/category.jspa?categoryID=151 and in the iTunes Forum http://discussions.apple.com/category.jspa?categoryID=149&start=0#threads there are quite some threads with similar problems.
    Sorry
    Stefan

  • I am trying to connect a Macbook Pro to a projector for a Powerpoint presentation. When I use a VGA cable, the color of the projected images are not good. When I use a USB cable, the projected image includes the presenter notes on my computer screen?

    I am trying to connect a Macbook Pro to a projector for a Powerpoint presentation. When I use a VGA cable, the color of the projected images are not good. When I use a USB cable, the projected image includes the presenter notes on my computer screen?

    To move an iPhoto Library to a new machine:
    Link the two Macs together: there are several ways to do this: Wireless Network,Firewire Target Disk Mode, Ethernet, or even just copy the Library to an external HD and then on to the new machine...
    But however you do choose to link the two machines...
    Simply copy the iPhoto Library from the Pictures Folder on the old Machine to the Pictures Folder on the new Machine.
    Then hold down the option (or alt) key key and launch iPhoto. From the resulting menu select 'Choose Library'
    and select the Library that you moved.  That's it.
    This moves photos, events, albums, books, keywords, slideshows and everything else.
    Your first option didn't work because you imported one Library to another. Every version and thumbnail is imported like a distinct photo, you lose all your Albums, Keywords etc., the link between Original and Previews is destroyed, the non-destructive editing feature is ruined and so on. In summary: it's mess.
    Your second option didn't work because you simply referenced her library on the old machine.
    Regards
    TD

  • My 1st gen iPad is not recognized in iTunes, help!  I have uninstalled, reinstalled, stoped and started the mobile....nothing is working.

    I have done everything I can find online to solve my problem, but I still have the same problem.  My 1st gen iPad is not recognized in iTunes!  Cannot sync!  Please, any suggestions from anyone?  Anyone else having the same problem?

    Hello casinojen,
    I would be concerned as well if my iPad was not recognized by iTunes.  Thank you for providing all the information with the steps you took in regards to this issue.  I found an article with a few more steps you can take (you can skip the steps you have already taken):
    iOS: Device not recognized in iTunes for Windows
    http://support.apple.com/kb/TS1538
    Thank you for using Apple Support Communities.
    Best,
    Sheila M.

  • Type 4 printer driver shows color is available when printer is not a color printer

    I am working on migrating to a new Windows Server 2012 print server.  I am trying to use the new version 4 printer drivers whenever possible.  I have noticed an interesting thing.  Here is an example.  When I added a new printer, an HP
    LaserJet P3005 black and white printer using the HP LaserJet P3004/P3005 PCL6 Class Driver, under "features" it reports Color as "Yes."  Now the printer is not color and I have noticed this on all of the other class 4 drivers for black
    and white printers.  Am I missing something or is this supposed to be this way?  The printers do print fine, I just wanted to know why this is showing up like this.

    Really a question for HP since it is their software.
    BUT:  A class driver can be used for a wide range of devices.  If the core class driver HP added for the P3005 is also used by devices that support color then the driver itself DOES support color even when the device does not.   There
    are a couple ways HP could code around this.  I do see that HP's PS version of the P3005 does not have a color option in Printing Defaults. 
    I have seen this type of issue from other vendors on previous operating systems, it's not just HP nor anything specific to class drivers although a class driver would expose this when the software to constrain the feature has not been added by the vendor.
    Alan Morris Windows Printing Team

  • My 1st generation iPad is not being recognized by my computer. The comuter recognizes my iPhone and my itouch still. Please help

    As it says in the title,my 1st generation iPad will not connect or be recognizes by my computer. Yet my computer has no problems with my iPhone or my itouch. What am I doing wrong? Something in the settings? I have no clue, please help

    Today, when I turned on my iMac, neither my bluetooth mouse or keyboard were recognized. I had to connect my old USB keyboard-mouse to type this message.
    And yes, I restarted my iMac, didn't help.
    Can someone help?
    PS: Barry, "resetting SMC" doesn't help

  • Just installed mountain Lion. Viewing a pdf sent to me using preview and some colors are appearing BLACK, however when I view the same PDF in Acrobat they are perfect and what they are suppose to be. WHY would PREVIEW showing a different color?

    Just installed mountain Lion. Viewing a pdf sent to me using preview and some colors are appearing BLACK, however when I view the same PDF in Acrobat they are perfect and what they are suppose to be. WHY would PREVIEW showing a different color?

    Here's what I've found on the issue:
    Pantone color definitions have changed (coinciding with CS6) — they are now "Pantone+" (I think that's what they're called). The "+" apparently means they're now LAB colors. Lab colors are not properly displayed in Preview (or in Finder previews) — they display as black (as far as I can tell, in all circumstances). I'm sure it's a tad more complicated than that, but that's the gist.
    Now the bad news — nobody seems to know anything about a fix or workaround (unless you convert your PDFs to process — this might be a fix for sending to clients). It causes issues for me in AI files — being able to view them in the finder (with previews) is a HUGE time saver for my workflow... when they're all black, not so much.
    In my chat with a director of product dev at Adobe, they placed the responsibility to fix on Apple (assuming Apple wants to support Pantone color definitions in their OS).

  • I lost all my colored tags in OSX - They are not listed when I go to Finder/Preferences/Tags.  How can I get them back

    I lost all my colored tags in OSX - They are not listed when I go to Finder/Preferences/Tags.  How can I get them back

    Hi, try this...
    Bootup holding CMD+r, or the Option/alt key to boot from the Restore partition & use Disk Utility from there to Repair the Disk, then Repair Permissions.
    Reboot.

  • [svn] 2692: Bug: BLZ-227 - When using JMS Destination, MessageClient and FlexClient not released from memory when the session times out .

    Revision: 2692
    Author: [email protected]
    Date: 2008-07-31 13:05:35 -0700 (Thu, 31 Jul 2008)
    Log Message:
    Bug: BLZ-227 - When using JMS Destination, MessageClient and FlexClient not released from memory when the session times out.
    QA: Yes
    Doc: No
    Checkintests: Pass
    Details: Fixed a memory leak with JMS adapter. Also a minor tweak to QA build file to not to start the server if the server is already running.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-227
    Modified Paths:
    blazeds/branches/3.0.x/modules/core/src/java/flex/messaging/services/messaging/adapters/J MSAdapter.java
    blazeds/branches/3.0.x/qa/build.xml

    Revision: 2692
    Author: [email protected]
    Date: 2008-07-31 13:05:35 -0700 (Thu, 31 Jul 2008)
    Log Message:
    Bug: BLZ-227 - When using JMS Destination, MessageClient and FlexClient not released from memory when the session times out.
    QA: Yes
    Doc: No
    Checkintests: Pass
    Details: Fixed a memory leak with JMS adapter. Also a minor tweak to QA build file to not to start the server if the server is already running.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-227
    Modified Paths:
    blazeds/branches/3.0.x/modules/core/src/java/flex/messaging/services/messaging/adapters/J MSAdapter.java
    blazeds/branches/3.0.x/qa/build.xml

  • I bought a hd movie on my iPad , however when I try to play on Apple TV 1st generation. It does not appear or says content not available. My TV is hd compatible

    I bought a hd movie on my iPad , however when I try to play on Apple TV 1st generation. It does not appear or says content not available. My TV is hd compatible

    AppleTV1 only supports HD upto 720p - chances are the iPad HD vserion is 1080p and beyond ATV1 capability.
    Also do not expect recent iTunes purchases to appear on AppleTV 1 store menus as purchased - ATV1 does not know about 'cloud access'.
    Best option is to download the 720p version (set in iTunes Preferences on computer iTunes) and sync/stream to AppleTV 1 from iTunes.

  • Simply put, I do not like like the new color coding "dots" and I do not like having to press the Command key before double clicking to open files in a new window. How hard would have been to include the old version of these two features?

    Simply put, I do not like like the new color coding "dots" and I do not like having to press the Command key before double clicking to open files in a new window. How hard would have been to include the old version of these two features?

    Apple - Mac OS X - Feedback

  • [svn:fx-trunk] 5812: Fixed a bug where direct use of Animation failed because AnimationProperty was not setting up its internal keyframes with correct duration information , so the animation would skip immediately to the end.

    Revision: 5812
    Author: [email protected]
    Date: 2009-03-31 11:34:56 -0700 (Tue, 31 Mar 2009)
    Log Message:
    Fixed a bug where direct use of Animation failed because AnimationProperty was not setting up its internal keyframes with correct duration information, so the animation would skip immediately to the end.
    Bugs: SDK-20356
    QE Notes: spark/effects Mustella tests currently hosed, couldn't run test suite
    Doc Notes: None
    Reviewer: Jason
    Testing: checkintests, Mustella effects tests could not be run (post-rename issues)
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-20356
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimationProperty.as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/animation/Animation.as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AnimateColorIns tance.as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AnimateShaderTr ansitionInstance.as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/FadeInstance.as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/MoveInstance.as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/ResizeInstance. as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/Rotate3DInstanc e.as
    flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/RotateInstance. as

    Hi
    Can you please try setting up full persmission in the security properties for everyone on the wsconfig folder C:\ColdFusion10\config\wsconfig  and restart ColdFusion Server.
    Swaraj

  • Color Adjust Filter and Paint Bucket not available in CS3

    I recently noticed that Colors in the Filter menu is not available in my install of Illustrator CS3. I also noticed that the Paint Bucket tool is missing. Both appear to be in the Plug-ins folder in their respective folders (Illustrator Filters and Tools) but are not available in the program. I am using Mac OS X version 10.4.11 on a PowerPC G4 running at 1.6 GHz with 1 GB of SDRAM. I have the Adobe Creative Suite 3 Web Premium package.
    There may be other problems with my install, but these are the two things I notices. Can anyone shed some light on why this is happening and how to fix it? I tried a re-install, but to no avail.

    Basically yes, but not quite. You may want to review the new features. The paint bucket was removed because it was, well, pointless in most cases. THe Live Paint tool is much more useful than the old Paint Bucket.

Maybe you are looking for

  • PKGBUILD for a module already present in the kernel

    I'm trying to package a svn version of a kernel module: the module is already in the stable kernel, but I'd like to have the latest build. My PKGBUILD works, except that the package won't install, because the .ko file is alreay in the filesystem, and

  • Message as yellow error

    Hi friends, I wanted to know abt message in report. I am fetching the records from two different database table i.e. kna1 & lfa1. Suppose I am not getting the data for kna1 but the data is available for lfa1. My req. is like if no data is available f

  • Php recordset outputting last value from while loop

    Hi all, I have an issue with a site I am making which lists radio buttons which are a set of donation options (some with predefined prices some with user dependant). I used jQuery to populate a textbox with the value of the radio buttons so the perso

  • MOV files not streaming to ATV

    I copied a few videos that we took on our itouch to my PC and they come across as MOV files.  I then added these to my itunes library. They appear in the library; however, they are not streaming to the ATV.  I started testing a few things and noticed

  • SCSI and Classic won't work

    Hi folks, I have read through some threads about SCSI but can't find anything I can use for my problem. I don't even know what kind of card I have --I'm technically challenged and don't get the inner working of a computer (this includes the system, I