0

I've been trying to format my Evernote notes (thousands of them) so that they are readable on any device.

I've accessed evernote storage on my Mac and saw folders of entries -- every folder contains a note.xhtml and a content.enml files, which directly stores note contents.

I can modify the *.xhtml file, and changes are reflected on Evernote client, but they just won't sync over to the server. Additionally, the *.enml file contains corresponding content to xthml file, but the change won't go there.

Is there any way I can neatly edit my notes, on the HTML level?

Thx!

1 Answer 1

0

In AppleScript, it's pretty easy to get and set the HTML. To actually manipulate the HTML you might want another language.

Here's how you read and write HTML content to a single selected Evernote note:

tell application "Evernote"
    set noteList to selection

    set n to item 1 of noteList

    set extractedHtml to HTML content of n

    set HTML content of n to "<p>Foo Bar</p><p>foo baz</P>"
end tell

Evernote provides some good examples of using AppleScript on their developer site. You can also use xsltproc for some more systematic manipulation. I have a read-only example of using xslt via AppleScript in a recent post of mine. This above little snippet might be enough of an example to tell you how to set the HTML content.

But, to give you a better answer, I'd need to know a little more about how you want to manipulate your notes. The above example just grabs the first item in your current selection and sets the content.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.