Color fonts creating word doc using PHP
Posted: Sun Jul 27, 2008 11:07 pm
does anyone know how to set the font color when creating a word document using PHP???
I've been looking for days....
$word = new COM("word.application") or die("Unable to instantiate Word");
$word->Documents->Open($template_file);
$word->Selection->Font->Bold = "1";
$word->Selection->Font->Italic = "1";
$word->Selection->Font->Name = "Arial";
$word->Selection->Font->Size = "18";
$word->Selection->TypeText("Your Name:");
$word->Selection->TypeParagraph();
I've been looking for days....
$word = new COM("word.application") or die("Unable to instantiate Word");
$word->Documents->Open($template_file);
$word->Selection->Font->Bold = "1";
$word->Selection->Font->Italic = "1";
$word->Selection->Font->Name = "Arial";
$word->Selection->Font->Size = "18";
$word->Selection->TypeText("Your Name:");
$word->Selection->TypeParagraph();