Jump to content

How to stop Evernote from creating hyperlinks to filenames and adding it after removing the hyperlinks?


Recommended Posts

If I paste a filename with an extension, Evernote converts the file to a hyperlink. Then I remove the hyperlink, Then if I hit Enter, shift Enter or the spacebar, it adds back the hyperlink! 
How to stop Evernote from doing this?

Link to comment
  • Level 5*
1 hour ago, abdu said:

If I paste a filename with an extension, Evernote converts the file to a hyperlink. Then I remove the hyperlink, Then if I hit Enter, shift Enter or the spacebar, it adds back the hyperlink! 

I'm not seeing this in the Evernote for Windows application. Is that what you're using? Please post a sample filename that doesn't work for you.

Link to comment
2 hours ago, DTLow said:

Where are you pasting from?

I know if I paste     "sample.file"   there's no hyperlink

sample.file doesn't but a name like side-nav-outer-toolbar.component.file does.

Link to comment
47 minutes ago, jefito said:

I'm not seeing this in the Evernote for Windows application. Is that what you're using? Please post a sample filename that doesn't work for you.

side-nav-outer-toolbar.component.file

Link to comment
  • Level 5*
28 minutes ago, abdu said:

sample.file doesn't but a name like side-nav-outer-toolbar.component.file does.

Confirmed.    

I think it's the .component. triggering this; I have no idea why

Link to comment
  • Level 5*

Kind of bizarre. I tried paring down the name. While "r.component.file" worked fine (no link generated), "ar.component.file" did generate the link. Actually, "ar.component" also generated the link, while neither "r.component" nor "ar.component" exhibited the problem. Smells like a bug, but it seems like a weird one.

In any case, what should work is after you paste it in add a space at the end, then select the link and press Ctrl+Shift_R (or right-click / "Remove") and it should stay as text.

But definitely a bug.

 
 
 
Link to comment
  • Level 5*
1 hour ago, dcon said:

Smells like "I think that looks like a web link so let me help you out"...

Understood, but why the difference in behavior between "ar.component" and "r.component"? That's what makes my nose wrinkle...

Link to comment
1 hour ago, dcon said:

Smells like "I think that looks like a web link so let me help you out"...

Evernote should not think it's a hyperlink unless there's http:// in the text. This is a classic case when software tries to be helpful,  but becomes buggy and annoying.

  • Like 1
Link to comment
  • Level 5*
1 hour ago, abdu said:

Evernote should not think it's a hyperlink unless there's http://

Except that there are other link types than "http://"; "https://", "file://", "ftp://", "mailto://" etc, are all valid URL prefixes (see e.g. https://en.wikipedia.org/wiki/URL). Beyond that, I'd be hard-pressed to say that the ones here look anything like web links (sorry, @dcon) or any other kind of URL, and it's already been shown that its behavior is pretty inconsistent, so it looks like a feature that needs some developer attention because bugginess.

I suppose you could ask for an option to turn it off, but that's just one more option hiding among many, and only @CalS knows them all.

 

  • Haha 1
Link to comment
8 minutes ago, jefito said:

Except that there are other link types than "http://"; "https://", "file://", "ftp://", "mailto://" etc, are all valid URL prefixes (see e.g. https://en.wikipedia.org/wiki/URL). Beyond that, I'd be hard-pressed to say that the ones here look anything like web links (sorry, @dcon) or any other kind of URL, and it's already been shown that its behavior is pretty inconsistent, so it looks like a feature that needs some developer attention because bugginess.

I suppose you could ask for an option to turn it off, but that's just one more option hiding among many, and only @CalS knows them all.

 

OK I meant those as well. I wasn't going to list them all. Yes it can be another option. It's a functionality that I didn't ask for or expect so there needs to be a setting to turn it on/off. I don't care if it's onemore option. Users don't deal with options in every Evernote use.

Link to comment
  • Level 5*
1 hour ago, jefito said:

I suppose you could ask for an option to turn it off, but that's just one more option hiding among many, and only @CalS knows them all.

Got me on this one big guy.  :ph34r:

Link to comment
  • Level 5

Just jumping in to confirm that apparently any combination of two alphanumerics followed by ".component" is enough to trigger creation of a hyperlink. The same is true of ".com", ".org", etc.

Putting on my Sherlock Holmes hat: Given that "component" seems to be a technical term for the elements making up a URI (Wikipedia: "The URI generic syntax consists of a hierarchical sequence of five components"), I suspect there is a bit of code that used "component" as a placeholder for any such element, and was either poorly written or not updated, with the result that the placeholder is interpreted as an actual element of a URL rather than a placeholder.

(Holmes picks up his violin, runs his long, sensitive fingers languorously along the strings, reaches for his bow, and begins to play a slow, reflective rendition of "Yakkety Yak" by the Coasters.)

Editing to ask @Shane D. if this can be passed along to the programmers, since (whether Sherlock is right or not) it clearly seems to be a bug.

  • Haha 1
Link to comment
  • Level 5*
1 hour ago, Dave-in-Decatur said:

Putting on my Sherlock Holmes hat: Given that "component" seems to be a technical term for the elements making up a URI (Wikipedia: "The URI generic syntax consists of a hierarchical sequence of five components"), I suspect there is a bit of code that used "component" as a placeholder for any such element, and was either poorly written or not updated, with the result that the placeholder is interpreted as an actual element of a URL rather than a placeholder.

Yeah, "component" the literal string shouldn't be used to ferret out URLs. Maybe they should have used regular expressions (star of the hit comedy "Now You Have Two Problems"):

# RFC-3986 URI component: URI-reference
(?:                                                               # (
  [A-Za-z][A-Za-z0-9+\-.]* :                                      # URI
  (?: //
    (?: (?:[A-Za-z0-9\-._~!$&'()*+,;=:]|%[0-9A-Fa-f]{2})* @)?
    (?:
      \[
      (?:
        (?:
          (?:                                                    (?:[0-9A-Fa-f]{1,4}:){6}
          |                                                   :: (?:[0-9A-Fa-f]{1,4}:){5}
          | (?:                            [0-9A-Fa-f]{1,4})? :: (?:[0-9A-Fa-f]{1,4}:){4}
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,1} [0-9A-Fa-f]{1,4})? :: (?:[0-9A-Fa-f]{1,4}:){3}
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,2} [0-9A-Fa-f]{1,4})? :: (?:[0-9A-Fa-f]{1,4}:){2}
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,3} [0-9A-Fa-f]{1,4})? ::    [0-9A-Fa-f]{1,4}:
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,4} [0-9A-Fa-f]{1,4})? ::
          ) (?:
              [0-9A-Fa-f]{1,4} : [0-9A-Fa-f]{1,4}
            | (?: (?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?) \.){3}
                  (?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)
            )
        |   (?: (?:[0-9A-Fa-f]{1,4}:){0,5} [0-9A-Fa-f]{1,4})? ::    [0-9A-Fa-f]{1,4}
        |   (?: (?:[0-9A-Fa-f]{1,4}:){0,6} [0-9A-Fa-f]{1,4})? ::
        )
      | [Vv][0-9A-Fa-f]+\.[A-Za-z0-9\-._~!$&'()*+,;=:]+
      )
      \]
    | (?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}
         (?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)
    | (?:[A-Za-z0-9\-._~!$&'()*+,;=]|%[0-9A-Fa-f]{2})*
    )
    (?: : [0-9]* )?
    (?:/ (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})* )*
  | /
    (?:    (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})+
      (?:/ (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})* )*
    )?
  |        (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})+
      (?:/ (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})* )*
  |
  )
  (?:\? (?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})* )?
  (?:\# (?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})* )?
| (?: //                                                          # / relative-ref
    (?: (?:[A-Za-z0-9\-._~!$&'()*+,;=:]|%[0-9A-Fa-f]{2})* @)?
    (?:
      \[
      (?:
        (?:
          (?:                                                    (?:[0-9A-Fa-f]{1,4}:){6}
          |                                                   :: (?:[0-9A-Fa-f]{1,4}:){5}
          | (?:                            [0-9A-Fa-f]{1,4})? :: (?:[0-9A-Fa-f]{1,4}:){4}
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,1} [0-9A-Fa-f]{1,4})? :: (?:[0-9A-Fa-f]{1,4}:){3}
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,2} [0-9A-Fa-f]{1,4})? :: (?:[0-9A-Fa-f]{1,4}:){2}
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,3} [0-9A-Fa-f]{1,4})? ::    [0-9A-Fa-f]{1,4}:
          | (?: (?:[0-9A-Fa-f]{1,4}:){0,4} [0-9A-Fa-f]{1,4})? ::
          ) (?:
              [0-9A-Fa-f]{1,4} : [0-9A-Fa-f]{1,4}
            | (?: (?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?) \.){3}
                  (?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)
            )
        |   (?: (?:[0-9A-Fa-f]{1,4}:){0,5} [0-9A-Fa-f]{1,4})? ::    [0-9A-Fa-f]{1,4}
        |   (?: (?:[0-9A-Fa-f]{1,4}:){0,6} [0-9A-Fa-f]{1,4})? ::
        )
      | [Vv][0-9A-Fa-f]+\.[A-Za-z0-9\-._~!$&'()*+,;=:]+
      )
      \]
    | (?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}
         (?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)
    | (?:[A-Za-z0-9\-._~!$&'()*+,;=]|%[0-9A-Fa-f]{2})*
    )
    (?: : [0-9]* )?
    (?:/ (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})* )*
  | /
    (?:    (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})+
      (?:/ (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})* )*
    )?
  |        (?:[A-Za-z0-9\-._~!$&'()*+,;=@] |%[0-9A-Fa-f]{2})+
      (?:/ (?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})* )*
  |
  )
  (?:\? (?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})* )?
  (?:\# (?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})* )?
)                                                                       # )

(courtesy of http://jmrware.com/articles/2009/uri_regexp/URI_regex.html#uri-40)

Whaddya think?

 

 

Link to comment
On 3/6/2020 at 9:12 AM, jefito said:

Understood, but why the difference in behavior between "ar.component" and "r.component"? That's what makes my nose wrinkle...

🤷‍♂️

No clue whether it's the EN editor or CEF. (I never looked at the EN javascript editor. I'm a C++ dude - I have to preserve my sanity!)

Link to comment
  • Level 5*
22 hours ago, dcon said:

No clue whether it's the EN editor or CEF. (I never looked at the EN javascript editor. I'm a C++ dude - I have to preserve my sanity!)

So how's that working' out for you?? 😼

Note that I am myself am a full time C++ dev, though I have some a bit of JavaScript in the past, not to mention being exclusively C for the first 8 or so years of my career. Not gonna make any claims about how much sanity is left in general though... :) 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...