php Writing of Word Document


$html = get_include_contents('test.php');
file_put_contents("wor33d.doc", $html);
function get_include_contents($filename) {
    if (is_file($filename)) {
        include $filename;
        return ob_get_clean();
    return false;

test .php

echo $html='<!DOCTYPE html>
<h1>My First Headidsdfsng</h1>
<p>My first paragrsdssdaph.</p>
<![if !mso]>
<table cellspacing="0" cellpadding="0" border="0" width="8.4cm">
    <td> Version</td>
<!--[if mso]>
<table cellspacing="0" cellpadding="0" border="0" width="8.4cm">
    <td>Microsoft Word version</td>




About rahul23134654

Hi, I am Rahul Meha , B.E. in (I.T.)
This entry was posted in PHP, Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s