'); require_once '../src/PhpWord/PhpWord.php'; // Return to the caller script when runs by CLI if (CLI) { return; } // Set titles and names $sampleFile = basename($_SERVER['SCRIPT_FILENAME'], '.php'); $isIndexFile = ($sampleFile == 'index'); $pageHeading = str_replace('_', ' ', $sampleFile); $pageTitle = $isIndexFile ? 'Welcome to ' : "{$pageHeading} - "; $pageTitle .= 'PHPWord'; $pageHeading = $isIndexFile ? '' : "