Page 1 of 1
Open msword file through php
Posted: Thu Dec 31, 2009 1:51 am
by neerajsingh
Hi friends,
i have upload a msword file(like cv), name is available in database and file is available in uplooad folder, i want to open this file in my page and then edit .
what should i do???
help pls.
Re: Open msword file through php
Posted: Thu Dec 31, 2009 1:53 am
by manojsemwal1
use opendir() and read file function
Re: Open msword file through php
Posted: Thu Dec 31, 2009 2:29 am
by neerajsingh
thanks for reply..
i have use this
$dir = "upload";
if (is_dir($dir)) {
if ($dh = opendir($dir)) {
while (($file = readdir($dh)) !== false) {
echo "filename: $file : filetype: " . filetype($dir . $file) . "\n";
}
closedir($dh);
}
}
this is display all files available in upload folder. i want to display one file content and edit it.
i m testing this in localhost.
Re: Open msword file through php
Posted: Thu Dec 31, 2009 5:32 am
by manojsemwal1
Frist u check the file u want to display is it exit or not ,
then give the file path which u want to be open............
for more detail read this article may be help u
http://webcheatsheet.com/php/working_wi ... s.php#read
Re: Open msword file through php
Posted: Thu Dec 31, 2009 6:14 am
by neerajsingh
hi,
this code display all file in dropdown. i m working in a job site.
after click on edit or preview it's look like..... see image

Re: Open msword file through php
Posted: Thu Dec 31, 2009 6:58 am
by manojsemwal1
NO Image
Re: Open msword file through php
Posted: Fri Jan 01, 2010 11:44 pm
by neerajsingh
hi manoj,
right click and view image.
neeraj
Re: Open msword file through php
Posted: Sat Jan 02, 2010 12:01 am
by manojsemwal1
Sorry No Image pl upload again..........
Re: Open msword file through php
Posted: Sat Jan 02, 2010 1:06 am
by neerajsingh
looks like