include php-files

Aug 17, 2011 at 1:40 PM

Hallo

I want to include a php file with prefefined styles.
When i use include ("nameOfFile.php"); I get an error.

Is this possible?

Thanks

Sep 10, 2011 at 6:56 AM

Hi

I placed the following at the top of the page before any inlude files and it solved the error with inlcude...

require_once '../../Classes/PHPWord.php';
$PHPWord = new PHPWord();
$PHPWord->setDefaultFontSize(12);
$section = $PHPWord->createSection();