4

i'm using PHPWord to read and write file as doc docx or html.

But i have a problem to get all content of a docx file for example.

is there an example to get content of docx file or html file ? (i tried to use sample of phpword, but don't help me)

My wish is to extract all text from a file (docx, html or other) and save it in database as pure text.

Anyone can help me please ?

1 Answer 1

-3

We can use file_get_contents php function to get content of files

$file = file_get_contents('./people.txt', true);

Hope this will help!

Sign up to request clarification or add additional context in comments.

1 Comment

Yes thanks for ur help, but i try to use the PHPWORD functions, to read docx. It's not same thing as file_gets_content. It's a different way to do this

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.