Feedback on NI Community

cancel
Showing results for 
Search instead for 
Did you mean: 

Forum: Broken URL parser

Hi all,


Let's say I want to provide a link to something I'm talking about, e.g. a particular NI product (http://www.ni.com/products/), without creating linked text.

 

In the above example, the closing parenthesis and comma get parsed as part of the URL when they should be left out.

Certified LabVIEW Developer
0 Kudos
Message 1 of 6
(6,062 Views)

Put your cursor in the link, then click on the chain link button of the editor.  Edit the path to remove the parenthesis and the comma, then save the link.  Retype the parenthesis and comma after the fixed link.

0 Kudos
Message 2 of 6
(6,059 Views)

Well, the whole purpose of pasting a raw URL in the first place was to bypass that link editor 🙂

 

Easier workaround is to add a space between the URL and the subsequent punctuation.

 

The original post is meant to be a "bug report"

Certified LabVIEW Developer
0 Kudos
Message 3 of 6
(6,054 Views)

If you continue typing after the url, the parser has no idea where the URL ends. Your "/" and ")" are both reserved characters. What do you propose? Should it automatically test urls and trim characters until it gets an URL that points to a valid page? Probably not!

Message 4 of 6
(6,041 Views)

@JKSH wrote:

Well, the whole purpose of pasting a raw URL in the first place was to bypass that link editor 🙂

 

Easier workaround is to add a space between the URL and the subsequent punctuation.

 

The original post is meant to be a "bug report"


I feel Altenbach gave a good explanation as to how you fell into this "bug". 

You don't necessarily have to go to the link editor to fix it.  If you are careful, you can put your cursor in the link and delete off the last 2 characters.  (If you don't do it quite right, you might wind up deleting the hyperlink aspect of it.)  As you noted, typing a space before you start typing any other characters will prevent other text from merging into the hyperlink.

 

Actually, I'm not even sure how you fell into that problem.  When I paste your link without the extra characters, typing /) doesn't merge with the link for me.  There are times where extra characters will merge with a link, and it just takes careful editing to fix it, but this wasn't one of them.

0 Kudos
Message 5 of 6
(6,017 Views)

@altenbach wrote:

If you continue typing after the url, the parser has no idea where the URL ends. Your "/" and ")" are both reserved characters. What do you propose? Should it automatically test urls and trim characters until it gets an URL that points to a valid page? Probably not!


No, auto-testing URLs is expensive. I think that the characters being reserved isn't the cause here; A full-stop is unreserved, but the following doesn't work either:

 

Visit http://www.ni.com. You will find cool stuff there!

 

 

I notice that Wikipedia's article editor correctly parses raw URLs with punctuation attached at the end. I tested "http://www.ni.com/" (oh, this was parsed correctly!) followed by

  • Double quotation marks
  • Closing parenthesis
  • Full-stop
  • Comma
  • Semicolon

Some combinations of the above like "/)," work too, but nonsensical combinations like "./" didn't. I'm guessing that their parser is programmed to recognize common end-of-sentence/phrase punctuation marks. This probably isn't high on NI's priority list, but I'd propose adding such an algorithm to the parser 🙂

 


@RavensFan wrote:

I feel Altenbach gave a good explanation as to how you fell into this "bug". 

You don't necessarily have to go to the link editor to fix it.  If you are careful, you can put your cursor in the link and delete off the last 2 characters.  (If you don't do it quite right, you might wind up deleting the hyperlink aspect of it.)  As you noted, typing a space before you start typing any other characters will prevent other text from merging into the hyperlink.

 

Actually, I'm not even sure how you fell into that problem.  When I paste your link without the extra characters, typing /) doesn't merge with the link for me.  There are times where extra characters will merge with a link, and it just takes careful editing to fix it, but this wasn't one of them.


I noticed that the NI forum's rich text editor sometimes auto-hyperlinks a URL that I copy+paste from my browser's address bar (I'm using Google Chrome). If this happens, subsequent characters that I type won't be merged into the link. Other times, the URL is pasted as plain text; URLs copied from other sources (e.g. a text file, my email client) always get pasted as plain text, unless the original source URL is already hyperlinked. Upon previewing or posting, it is the plain-text-to-hyperlink parser that trips up.

Certified LabVIEW Developer
0 Kudos
Message 6 of 6
(5,997 Views)