By ass45sin on
Hi All,
I'm using drupal for managing my ebook collection using CCK and Views and I'm trying to create links to local files on my HD using the file: protocol, works wonderfully in notepad created HTML but not when I create them on Drupal it simply refuses to follow the link. or some reason if I can open the link by right clicking and use "Open Link in IE Tab".
I've search the forum, found someone having similar problem in http://drupal.org/node/97524 and http://drupal.org/node/93853 but none of the solutions seems to work for me.
I'm using Drupal 5.2, And all the latest CCK, Views and Pathauto.
Any help will be greatly appreciated.
Thanks.
Comments
slash slash slash
It would help if you pasted the source of the HTML link that doesn't work.
Just for curiosity, try DRAGGING a local file into your browser and looking at the URL the browser natively uses to identify that.
...Count the slashes...
IE forgives you. Other implementations may not
This has a complete explanation
http://www.apps.ietf.org/rfc/rfc1738.html
.dan.
How to troubleshoot Drupal | http://www.coders.co.nz/
.dan. is the New Zealand Drupal Developer working on Government Web Standards
death by a thousand cuts
Was out of the office during national holiday.
Aye.. I definitely did slash slash slash...
The links that I would like to have would be like these
file:///I:/Ebooks/
file:///I:/Ebooks/Stonesoft/Administrator_Guide.pdf
And I've already created the links like these
<a href="file:///I:/Ebooks/">Our Ebooks</a><a href="file:///I:/Ebooks/Stonesoft/Administrator_Guide.pdf">Administrator_Guide</a>The link does show on the status bar on Firefox. The thing is if I did the html in notepad firefox would follow the link and somehow drupal doesn't seems to allow file:// protocol... which is in my humble opinion weird..
I also tried using the pipe instead of colons as explained at the http://www.cport.com/support/webtroubleshooting.htm
<a href="file:///I|/Ebooks/">Our Ebooks</a>And also tried without trailing slash
<a href="file:///I|/Ebooks">Our Ebooks</a>But both give the same effect. Can open them on notepad created html.. doesn't seems to work on drupal.
<@__________@;
Thanks
Ed
EDIT: added
tagsEDIT AGAIN: seems like it is a restriction done by Mozilla
Seems like mozilla browsers refuse to follow file: links on pages fetched with the HTTP protocol
http://kb.mozillazine.org/Firefox_:_Issues_:_Links_to_Local_Pages_Don't_Work
Work around is available on the website.
Case is closed.
Thanks again dman ^_________^
OK, so it's a browser
OK, so it's a browser sandbox thing. That's logical, better safe than sorry ... however a warning or a confirm would have been nice.
Sorta cripples intranets I would have thought .... but if the fix works .. cool.
(I remember the old practical joke - "I just hacked into your computer, Click here to see the listing of your C: to prove it ;-)
.dan.
How to troubleshoot Drupal | http://www.coders.co.nz/
.dan. is the New Zealand Drupal Developer working on Government Web Standards