If user puts URL like: www.example.com to the Link field, link will be created as and so parsed as internal. At the same time it works fine in Link module output.

CommentFileSizeAuthor
#2 1697446-2.patch1.12 KBa.mikheychik
#1 1697446-1.patch922 bytesa.mikheychik

Comments

a.mikheychik’s picture

StatusFileSize
new922 bytes

Here is a patch to fix this problem. At least it works for me.

It checks if this path recognized as internal and then checks if this path is available in drupal system. So if check fails, it adds http:// protocol.

a.mikheychik’s picture

StatusFileSize
new1.12 KB

Sorry, one more check was needed, added.

hass’s picture

Status: Active » Closed (duplicate)

Thank you very much for your patch, but could you join #1535594: Allow other modules to reuse the link building logics, please? I'm marking this as a duplicate for now.

drupalfan81’s picture

Issue summary: View changes

has this issue been fixed in the production release versions? I have a site where users input the web address for their listing. Sometimes users fill it in as http://www.sitename.com but often they just fill in www.sitename.com. I have even tried stating PLEASE ADD http:// in your URL but they still leave it off.

For some reason this module takes these www.sitename.com and tags them as invalid links, and in the link report they are in the list as 404 NOT found. So if a user inputs "siteabc.com" in the URL field it will display on the link report as a 404 with the URl as: http://www.mydrupalsite.com/siteabc.com.

This seems like a pretty big bug. Can someone tell me if this will be fixed soon or how I can hack the module to get it to work in this way?

Thanks!

hass’s picture

You may enable an input filter for this, too.

drupalfan81’s picture

@hass, what do you mean?