Ask Your Question
0

convert docx to html in command line not working

asked 2015-04-10 07:10:43 +0200

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

Hi, I tried to convert docx to html file using libreoffice4.4 in command line execution. I'm using below code this gives nothing. Please give me some suggestions to fix this.

<?php
chdir('/usr/bin/');
$myCommand = "libreoffice4.4 --headless  -convert-to html /home/username/public_html/docx/test.docx -outdir /home/username/public_html/docx/";
exec ($myCommand);
?>
edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
0

answered 2015-05-08 07:53:02 +0200

susa gravatar image

Hi, Any update? I am missing anything? Please correct me....

edit flag offensive delete link more
0

answered 2018-05-30 14:29:43 +0200

I too need the same Answer...! If anyone knows please help me on this.

edit flag offensive delete link more

Comments

1

So did you use the very same command line? Then it's natural that you didn't get the expected result, just like the OP: if you read the documentation, you'll see that --outdir is part of --convert-to (and thus cannot be separated by filename from the latter), and that both should have two --, not one.

Mike Kaganski gravatar imageMike Kaganski ( 2018-05-30 16:01:01 +0200 )edit

Also, if you's read the guidelines to asking (mentioned from the How to use the Ask site link on the Ask main page), you'd not use "answer" to ask your question, knowing that answers are for answering questions.

Mike Kaganski gravatar imageMike Kaganski ( 2018-05-30 16:04:48 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2015-04-10 07:10:43 +0200

Seen: 1,414 times

Last updated: May 30 '18