1 From
: Paul Southworth
<pauls@etext
.org
>
2 Subject
: antiword PHP script
3 Date
: Thu
, 24 Oct
2002 14:01:05 -0700 (PDT
)
5 Please find attached a trivial example of using a web form to process an
6 uploaded Word doc to text using antiword
. Perhaps other antiword users
13 A PHP script to convert uploaded MS Word docs to text using antiword.
14 This script is public domain, no copyright.
18 function print_form() {
20 <html
><head
><title
>antiword
</title
></head
><body
>
21 <form method
=post action
=antiword
.php enctype
="multipart/form-data">
22 <input name
=upload type
=file
>
23 <input type
=submit name
=submit value
=convert
>
28 if ($_FILES['upload']) {
29 header ("Content-type: text/plain");
30 system("/usr/local/bin/antiword " . $_FILES['upload']['tmp_name']);