1.download qt-win project
http://kde-cygwin.sourceforge.net/qt3-win32/
The qt3 project for windows if you wanna compile qt4 download qt4 opensource edtion
2.To build qt under windows ,you can use MS VS,MingW,DEV CPP ….
1.download qt-win project
http://kde-cygwin.sourceforge.net/qt3-win32/
The qt3 project for windows if you wanna compile qt4 download qt4 opensource edtion
2.To build qt under windows ,you can use MS VS,MingW,DEV CPP ….
Ms Office doc =>pdf => picture (JPEG,PNG,etc..)
1. Install openoffice.org-headless,openoffice.org-calc,openoffice.org-writer,openoffice.org-draw,imagemagick.Under windows system, both imagemagick and ghost script were needed
2.Start openoffice as service
#!/bin/bash
/usr/lib64/openoffice.org/program/soffice.bin -headless -nologo -norestore -accept=”socket,host=localhost,port=8100;urp;StarOffice.ServiceManage” &
3.DOWNLOAD JODConverter ,and start it
4.Convert doc to pdf
function convert2pdf($inputData,$inputType,$outputType=”application/pdf”){
require_once ‘HTTP/Request.php’;
$request = new HTTP_Request(“http://localhost:8080/convert/service“);
$request->setMethod(“POST”);
$request->addHeader(“Content-Type”, $inputType);
$request->addHeader(“Accept”, $outputType);
$request->setBody($inputData);
$request->sendRequest();
return $request->getResponseBody();
}
WARNING Install pear HTTP_Request First
# pear intall HTTP_Request
5.Convert pdf to picture
function convert2jpeg($pdffile,$dest){
if(!file_exists($pdffile)){
return;
}
exec(“convert -quality 70 -density 250 -geometry 25% $pdffile $dest”);
$dir = dirname($dest);
return $dir;
}