Converting HTML to MSWord-Readable format - html

I want to convert / transfer HTML Transitional Code into a "MS-Word readable"-format...pdf would also do the job.
The converter should be a standalone program which I can reach by console...
P.S.: The input is created by TinyMCE and after this stored in a OracleDB
P.P.S.: It should be able to understand CSS for div-positioning
P.P.P.S: It should be Open Source :)
Thank you :)

Looks like your are looking for something like wkhtmltopdf.
Here is a guy who blogged about his integration of that tool. It can convert HTML to PDF and includes css: http://beebole.com/en/blog/general/convert-html-to-pdf-with-full-css-support-an-opensource-alternative-based-on-webkit/

Related

Get HTML of page with awesomium

How do I get the HTML of a web page in awesomium with C++?
I've searched and apparently you can only do it with webcontrol in C# or in Java. Using the sample hello I tried doing:
JSValue theVal( view->ExecuteJavascriptWithResult(WSLit("document.getElementsByTagName('html')[0].innerHTML"),WSLit("")));
but it does not work. any ideas? and please in c++ as i am aware that you can do this in C# and Java.
Using Javascript you can do it like this:
web_view->ExecuteJavascriptWithResult("document.getElementsByTagName('html')[0].innerHTML");
also you can use:
web_view->CopyHTML();
and then get HTML from the clipboard. I am not sure if there is another way of getting HTML without using Javascript.

QT HTML Parser (+XQuery)

I'm looking for a QT HTML parser tool.
I have some html source code and I'd like to use XQuery on it.
I already tried using QWebPage + QWebElement, but I don't like this solution cause firstly it doesn't works on non-gui thread (because of QWebPage) and because we can't apply XPath but CSS Path.
The other solution I tried is QXmlQuery, it works great, but the only problem is that it doesn't works if there is an error on the page. For example, the first page I tried was missing systemId (in the DOCTYPE tag), so the parsing was aborted.
I heard we can use gecko for parsing but I have no idea how to use it with QT.
Have you some suggestions ?
Thanks
I recommend that you use tidy on your HTML page and then process it with XQuery.
Zorba is a C++ XQuery processor that provides a tidy module.
You can find a live example at http://www.zorba-xquery.com/html/demo#tQZu6aq1K4KoGJm9m0oIPwKRt04=
BaseX got a QT client and can use TagSoup for cleaning up HTML documents.
I'm sorry I cannot provide you with an QT example as I don't know QT at all.

XML -> XSL -> HTML edit file, and SAVE changes in xml WITHOUT asp

I have an XML file that I've transformed with xsl and loaded into a browser as html. That html is editable using a rich text editor by the user. When they're done I need to transform their html edits back to the original xml document.
One solution I've found is using ASP: http://www.w3schools.com/xsl/xsl_editxml.asp
But I'm using Apache and I don't have ASP installed, and I'm wondering if there is an easier/better way to do this without using ASP.
Or is ASP the only way?
Thanks =)
The solutiton that you found doesn't do what you describe. It only presents the data from the XML as a form, and lets the user edit the values. That's not very complex, and you can do that using pretty much any other server side language, like PHP for example.
What you describe, on the other hand, is quite complex. It involves examining the XSL and the HTML to identify the parts of the HTML code that was created using specific XML data, so that changes can be reflected back. That's not something that is done with a simple ASP script like that.
If you design an XSL transformation for both directions, XML to HTML and HTML to XML, comparing the source XML and resulting user XML should be a much easier problem to solve.

JavaDoc editor for Eclipse to create formatted text

im looking for a small plugin which let me create formated javadoc. at the moment im doing it with word (or http://tinymce.moxiecode.com/examples/full.php ) and save the text as a html file which then can be used but i think there must be a easier solution to create nice looking java doc..
JDocEditor is an Eclipse plugin that lets you write Javadoc in a WYSIWYG editor window:
http://www.certiv.net/projects/jdoceditor.html
You can probably use this
http://jautodoc.sourceforge.net/

Print HTML on webpage

I want to print some java, jsp code on webpage in an indented format.
Is There a tool that would do it, right now I have to use &nbsp, &lt, &gt to get it done, which is very painful
You could just use the <pre> tag...
If you have access to a text editor, you could just use "Find & Replace..."
Just replace:
< with <
> with >
(two spaces) with
You would have to find the dynamic way of storing and printing the text for example with the combination of javascript and php you can easily achieve this with the help of free and open text editor like WYSIWYG Editor
Have a look at this URL : http://www.openwebware.com/
this can provide a complete solution to you. and embedding on your website should not be a problem, just google something like embedding WYSIWYG Editor etc. you can always find many good tutorial that explain step by step how to do this..
hope this helps you..