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.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 1697446-2.patch | 1.12 KB | a.mikheychik |
| #1 | 1697446-1.patch | 922 bytes | a.mikheychik |
Comments
Comment #1
a.mikheychik commentedHere 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.
Comment #2
a.mikheychik commentedSorry, one more check was needed, added.
Comment #3
hass commentedThank 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.
Comment #4
drupalfan81 commentedhas 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!
Comment #5
hass commentedYou may enable an input filter for this, too.
Comment #6
drupalfan81 commented@hass, what do you mean?