Jump to content

Archived

This topic is now archived and is closed to further replies.

kylescousin

Annoying problem with pasting HTML or PHP in evernote

Recommended Posts

Hi,

 

Evernote messes up html code that gets pasted in. At first I thought there were some hidden chars in the copied text causing this, but when pasting in notepad++ for example, it does show correct.

So here is the text I copy from the editor:

<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1"><span class="sr-only">Toggle navigation</span><span class="icon-bar"></span><span class="icon-bar"></span><span class="icon-bar"></span></button>

Then paste it in evernote, it turns into this:

 

< button type= "button" class= "navbar-toggle collapsed" data-toggle= "collapse" data-target= "#bs-example-navbar-collapse-1" >  <span class= "sr-only" >Toggle navigation</span >  <span class= "icon-bar" ></ span>  <span class= "icon-bar" ></ span>  <span class= "icon-bar" ></ span></button ></nav>

Look at all the spaces that are added. Can this please be fixed or offer a workaround. When pasting as plain text it pastes correctly, but then all the color coding is gone, and I want to keep that.

 

Share this post


Link to post

Which Evernote client are you referring to? Windows? Mac? Web? Android? iOS?

Share this post


Link to post

Which Evernote client are you referring to? Windows? Mac? Web? Android? iOS?

 

Forgot to mention, it's the windows desktop client.

The editor I'm copying from is PHPStorm.

Share this post


Link to post

Evernote doesn't (yet) play well with code,  though we were being promised editor enhancements at one stage.  Short term workaround is to use another app that will support your formatting,  and save those files in the note as well as / instead of the bare code.  It's one extra step to open the attachment to copy/ paste into or from,  but at least it doesn't involve extra editing.

Share this post


Link to post

×
×
  • Create New...