title: How to include CSS in a DOC file created from HTML using PHP
body: <p>The doc is generated but it's not getting the external CSS file. I am using .css files but when I generate the doc file it's not adding the CSS classes.</p>
  
  <p>My code:</p>
  
  <pre><code>&lt;?php
   header("Content-type: application/vnd.ms-word");
   header("Content-Disposition: attachment; file=yourcoolwordfile.doc");
  ?&gt;
  
  
  &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
    &lt;head&gt;
      &lt;link href="&lt;?php echo Yii::app()-&gt;request-&gt;baseUrl; ?&gt;/css/base.min.css" rel="stylesheet" type="text/css"&gt;
      &lt;link href="&lt;?php echo Yii::app()-&gt;request-&gt;baseUrl; ?&gt;/css/fancy.min.css" rel="stylesheet" type="text/css"&gt;
      &lt;link href="&lt;?php echo Yii::app()-&gt;request-&gt;baseUrl; ?&gt;/css/main1.css" rel="stylesheet" type="text/css"&gt;
    &lt;/head&gt;
    &lt;meta http-equiv="Content-Type" content="text/html; charset=Windows-1252"&gt;
    &lt;div id="sidebar"&gt;
      &lt;div id="outline"&gt;&lt;/div&gt;
    &lt;/div&gt;
    &lt;div id="page-container"&gt;
      &lt;div id="pf1" class="pf w0 h0" data-page-no="1"&gt;
        &lt;div class="pc pc1 w0 h0"&gt;
          &lt;img class="bi x0 y0 w0 h1" alt="" src="bg1.png"/&gt;
          &lt;div class="t m0 x1 h2 y1 ff1 fs0 fc0 sc0 ls0 ws0"&gt;my senior care roadmap&lt;/div&gt;
          &lt;div class="t m0 x1 h3 y2 ff1 fs1 fc1 sc0 ls0 ws0"&gt;prepared for : &lt;/div&gt;
          &lt;div class="t m0 x2 h2 y3 ff1 fs0 fc1 sc0 ls0 ws0"&gt; &lt;/div&gt;
          &lt;div class="t m0 x3 h4 y4 ff1 fs2 fc2 sc0 ls0 ws0"&gt;© 2016 ageModern | info@agemodern.com | 888.460.0007 | &lt;/div&gt;
          &lt;div class="t m0 x4 h5 y5 ff1 fs3 fc0 sc0 ls0 ws0"&gt;03.26.2016&lt;/div&gt;
          &lt;a class="l" href="mailto:info@agemodern.com"&gt;
            &lt;div class="d m1" style="border-style:none;position:absolute;left:287.492343px;bottom:11.789197px;width:132.096000px;height:14.712000px;background-color:rgba(255,255,255,0.000001);"&gt;&lt;/div&gt;
          &lt;/a&gt;
        &lt;/div&gt;
        &lt;div class="pi" data-data='{"ctm":[1.000000,0.000000,0.000000,1.000000,0.000000,0.000000]}'&gt;&lt;/div&gt;
      &lt;/div&gt;
    &lt;/html&gt;
  </code></pre>