Simple Machines Community Forum

SMF Development => Bug Reports => Fixed or Bogus Bugs => Topic started by: jsx on November 04, 2022, 09:51:36 AM

Title: Converting words into a link
Post by: jsx on November 04, 2022, 09:51:36 AM
Hello.

In SMF 2.1, when someone puts a website address in a post, for example simplemachines.org, this address is automatically converted into a link. But there are some users who write the text as they write, i.e. like this: This is my test post. This.post...

And as can see, these words should not convert into a link. Maybe it would be a good idea to implement in 2.1 that only the entered address would be converted into a link. I think this conversion should only work if the domain is entered.
Title: Re: Converting words into a link
Post by: Kindred on November 04, 2022, 10:04:37 AM
Thing is... with new tlds, who knows what might be a valid url
Title: Re: Converting words into a link
Post by: Sesquipedalian on November 04, 2022, 11:38:23 AM
As a matter of fact, we do know which ones are valid, or at least which ones end with a valid TLD.

For example, ".post" is indeed a valid TLD (https://www.iana.org/domains/root/db) these days, so This.post is a valid domain name just like example.com or any other.

In @jsx's example, the user may not have intended to enter a domain name, but they did. SMF's autolinker can't read minds; it can only read the text it is given. So if the user doesn't want the unintended URL to appear in their post, the solution is to fix their typo and put a space between the end of one sentence and the beginning of the next.
Title: Re: Converting words into a link
Post by: jsx on November 04, 2022, 04:17:55 PM
I understand, thanks for the clarification.
Title: Re: Converting words into a link
Post by: shawnb61 on November 27, 2022, 03:36:43 PM
I am closing this out as it is not a bug. 

Yes, they are creating far too many tlds...  But SMF needs to honor the valid tlds.