RTF to Wiki Converter? - wiki

I would like to convert 100+ RTF files to Wiki Markup, but I can only find "Wiki to RTF" converters on the web and even here on StackOverflow.
I only need RTF --> Wiki Markup
Is there anything like this out there?

I simply asked the wrong question.
Did some research and found out that there is no Converter which converts RTF directly to a "Wiki format".
The "better" question: Save Word file as Wiki markup.
There are some approaches using Microsoft Word to save as .txt (Wiki markup):
http://www.mediawiki.org/wiki/Extension:Word2MediaWikiPlus
http://www.microsoft.com/en-us/download/details.aspx?id=12298
http://techwiki.openstructs.org/index.php/Wiki_converters
http://www.consumingexperience.com/2008/03/convert-word-doc-or-webpage-to-wiki.html
Good luck!

It may be unwieldy with hundreds of files, but I have used wikEd to convert RTF and Word formatted text to wiki markup.
Wikedbox is a usable implementation of wikEd without installing it:
http://www.appropedia.org/index.php?title=Appropedia:Wikedbox&action=edit
'''Wikedbox HELPS YOU CONVERT HTML (WEB FORMATTED CONTENT) TO MEDIAWIKI.'''. More instructions at [[Appropedia:WikEd]].
INSTRUCTIONS:
If you're not in edit mode, click the "edit" tab now.
Paste in your content.
Click the red [W] to convert. (Middle row, second block from the left.)
Your text is ready to be copied and used on your wiki page. (You may need to make further corrections.)
'''DO NOT SAVE THIS PAGE'''. (You'll be blocked from doing so, anyway, unless you're an admin.)

You can use Pandoc:
pandoc -s README -o example.rtf
This will convert your file to Markdown. I don't know which Wiki you want to use and If it understands Markdown, but I thinl you can also convert it to MediaWiki or other output formats (see the Pandoc User manual).

Related

R markdown show markdown output in .Rmd

I remember there was a time that when you type # in R markdown it will immediately transfer to the heading output. Also, when you type **bold** it will immediately show the text in bold. But now I can't find a way to do this.
Is it possible to show the markdown output in the .rmd document? Thanks!
This behaviour will depend on the text editor you use. Some Markdown editors have a "What You See Is What You Get" (or WYSIWYG) philosophy that will do exactly what you describe. You can find examples of WYSIWYG Markdown editors online, I personally have only tried Typora. But as far as I can tell, none of them seem to support Rmarkdown (perhaps someone has made an Rstudio add-in?).
On the other hand, in the early days of knitr, it used to support Lyx (I don't know if it still does), which is maybe closer to what you have in mind? See this post for an example: https://yihui.org/knitr/demo/lyx/

To interrupt org-latex-pdf-process to regexp-replace some string of the .tex intermediate file and continue to export

I am using org-mode to write some article now. Org-mode is really a great tool to outline a article with great table and image support.
Org-mode can display inline .png image but .pdf file. Because now org-mode can not control the width or height of shown inline image, so i use matplotlib to produce low dpi .png image in PNG folder for inline display and higher dpi pdf image in PDF folder for finally article export.
In .org file, the image link is like [[file:PNG\*.png]] and \includegraphics{PNG\*.png}in the produced .tex file. Then emacs will use org-latex-pdf-process to render it to pdf file. What I want is that before or in org-latex-pdf-process, a regexp replace function is added to replace the \includegraphics{PDF\*.pdf}, and then produce the final pdf file.
I am a beginner to elisp, so do not know how to put some code here. Can anyone help me?
With help of some great guys in org-mode mailing list, I finally got the perfect solution.
The detailed can be found in http://lists.gnu.org/archive/html/emacs-orgmode/2014-04/msg01014.html.
The solution is offered by John Kitchin in github: https://github.com/jkitchin/jmax/blob/master/ox-manuscript.el. The functions he wrote really satisfies what I need, which gives me a great help.
Many thanks to him.
Any questions can be posted to ox-manuscript.el.
Cheers!

Converting HTML file to PDF using Win32/MFC

As part of my application, my client has requested that I include an automated e-mailing system. As part of this system, I generate HTML code and use automation to send it via. Outlook.
However, they also require a PDF copy of the HTML document to be sent as an attachment. My initial attempts involved using libHaru, which proved difficult to use efficiently, as I was required to create the PDF document from scratch, which required computation of the position of each of the lines in a table, and positioning of all the text, etc.
I was wondering if there would be a way to programmatically convert HTML code (or an HTML file if need be) into a PDF document either by using Win32/MFC itself or an external library.
Thanks in advance!
EDIT: Just to clarify, I am looking for solutions which minimize external dependencies.
You should evaluate this utility wkhtmltopdf:
http://code.google.com/p/wkhtmltopdf/
You can call it from the command line without the need to run a setup.
I use it generating my output documents as html then cal a ShellExecute(...) to convert it to PDF. It's great!
Inside uses webkit + qt. So compability with modern HTML is OK.
Hope it helps.
I'd take a look at PDF Creator, which can be used as a COM object (that acts pretty much like a printer). I haven't used it to print HTML, so I'm not sure, but my guess is that you'll probably end up having to instantiate a web browser control to render the HTML, and then feed it from there to the PDF control.
Some possible answers are in this thread:
C++ Library to Convert HTML to PDF?
Not sure if they will satisfy your particular requirements, but these might at least get you started.
Edit:
Some other possible options here.
Not MFC but you can try QtWebKit. It can render and export HTML to PDF, PNG, JPEG

ColdFusion - converting HTML webpage to Word or PDF document

I have a webpage, where user has a possible to Print this page OR to save it on his/her computer.
How may I save it as a Word or PDF document?
Thanks.
For the MS Word requirement, most versions of Office can interpret basic html/xml. So you might consider the old cfcontent hack as a simpler alternative to POI. (The Word package is not quite as mature as the spreadsheet package.)
Basically you generate html, but use cfheader/cfcontent to tell the browser the content is really a Word document. It is obviously not a true MS Word file. But it is simpler than most options.
http://msdn.microsoft.com/en-us/library/aa155477.aspx
<cfheader name="Content-Disposition" value="attachment; filename=someFile.doc">
<cfcontent type="application/msword">
... your html code here ...
For microsoft office documents you can use the Apache POI project. This means in your coldfusion code you need to use some basic java code to call the poi methods.
However, if you choose the pdf document things are quite easier. You can use the cfdocument tag with the PDF format option
Using the POI or OpenOffice interface (depending on your version) you can create a Word doc. Using the built-in PDF generation tools, you can create a PDF doc. HOwever, you can only present that as an option.
There is no way to override the save/print menu functions. No matter how you handle it, I cna save the source document instead of the .doc or .pdf. Similarly, you cannot prevent me from printing the original document, instead of a prepared PDF.
Here is a method that has worked for me:
Create PDF or FlashPaper with ColdFusion
However, just like printing, you will have to sacrifice some graphics, so this would be best used for exporting content (but as you did not specify, I'm just clarifying that this is possible but at a cost).
Hope that helps.
Use cfdocument to display as a PDF, then they can just click the disk image to save it to their computer. Or you can use the filename= attribute of cfdocument to assign a filename to it, and it will prompt them to save it instead of displaying in the browser.

How to convert pdf documents to html files?

Should remain format,looks almost the same as original.
A couple of examples:
This page discusses how to use software called pdftohtml to convert in Ubuntu.
This page lists shareware (probably Windows) which converts PDF to various MS formats, including htm.
I even found a couple of videos (a Google video and one on www.break.com). I didn't look at them because I think they'll just describe how to use some software.
These are obviously unsatisfactory if you want to know how to do it yourself.
I think PDF started out as a compressed 'postscript' file, but these days would probably contain images (of scanned documents, for example).
If that's the case, don't bother looking for text, you can extract the images and create HTML pages to display the images. This should at least enable you to preserve the formatting.
At the very least, you could screen-capture the PDF pages to create the images. Crude, I know, but it would work whether the PDF was postscript or images.