emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] HTML --> Org-mode?


From: Tory S. Anderson
Subject: Re: [O] HTML --> Org-mode?
Date: Mon, 26 Jan 2015 15:31:10 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Using the magic wizard program Pandoc, I just had success with a simple little 
example: 

    pandoc -o test.org test.html

Input test.html:
    <html>
      <body>
          <strong>TEST strong!</strong>
        <div class='table'>
          <div class='cell'>Cell 1</div>
          <div class='cell'>Cell 2</div>
          <div class='cell'>Cell 3</div>
          <div class='cell'>Cell 4</div>
        </div>
      </body>
    </html>

Output test.org:
    *TEST strong!*
    Cell 1
    Cell 2
    Cell 3
    Cell 4

I'm not sure how sophisticated the strings you are dealing with, but pandoc 
might do the trick for you. 
- Tory


Matt Price <address@hidden> writes:

> Hmm,
>
> Looks like I asked this about a year ago and didn't follow up on it.
> Does anyone know a way to generate org-mode syntax from an html
> string? I would like to extend zotxt slightly (see my last post) and
> at present zotxt can pull citations 7 bibliography entries from Zotero
> only in plain-text and HTML form. The plaintext form loses
> information, so I would like to translate the HTML into org-mode
> syntax. 
>
> Since this would have to happen in the context of an 
>
> (org-add-link-type )
>
> invocation, it would be best if this could be done directly in emacs
> somehow... 
>
> Thanks as always,
>
> Matt



reply via email to

[Prev in Thread] Current Thread [Next in Thread]