PHP Classes

How specify css file?

Recommend this page to a friend!

      MsDoc Generator  >  All threads  >  How specify css file?  >  (Un) Subscribe thread alerts  
Subject:How specify css file?
Summary:How do I specify a separate css file to format the .doc output?
Author:Dave Williams
Date:2011-03-10 07:32:49

  1. How specify css file?   Reply   Report abuse  
Dave Williams - 2011-03-10 07:32:50
I've looked and the program seems to have the capability to specify a separate css file (which will format the final .doc output file) but I can't get it to work.

I've tried to specify the css file in the clsMsDocGenerator.php file at:

function clsMsDocGenerator($pageOrientation = 'PORTRAIT', $pageType = 'A4', $cssFile = '/home/user/public_html/file.css');

and in that file.css I specify a format:

#greenFormat {
color: #00ff00;

and in the file which creates the .doc file I specify both the file location and #greenFormat:

$doc = new clsMsDocGenerator('PORTRAIT', 'A4', '/home/user/public_html/file.css');

$greenFormat = array('style' => '#greenFormat');

but I can never get the .doc generator to obey the separate file.css

I'm sure I'm doing something simple wrong - but I don't know the correct syntax. Any ideas?