Open
Bug 1344266
Opened 8 years ago
Updated 7 months ago
Attached file-link to event/task won't open: "Only http:// and https:// URLs are valid"
Categories
(Calendar :: General, enhancement)
Tracking
(Not tracked)
NEW
People
(Reporter: Johannes.mozdev, Unassigned)
References
Details
Attachments
(1 file, 1 obsolete file)
1.35 KB,
patch
|
MakeMyDay
:
feedback+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:51.0) Gecko/20100101 Firefox/51.0
Build ID: 20170201175806
Steps to reproduce:
Create a task with an URL attachment with file-protocol
Actual results:
Clicking on that URL when the task is selected won't do anything except showing following error in console:
Invalid URL provided: file:///path/to/file.pdf Only http:// and https:// URLs are valid.
source: chrome://calendar/content/calApplicationUtils.js
line: 27
Only double or right clicking the URL when the task editing window is opened is working.
Expected results:
Clicking a URL pointing to a file should open the file also when the task is displayed. If it's not working, then the warning should shown to the user and not hidden in the error console.
Updated•8 years ago
|
Attachment #8843381 -
Flags: review?(makemyday)
Updated•8 years ago
|
Assignee: nobody → Johannes.mozdev
Comment 2•8 years ago
|
||
Comment on attachment 8843381 [details] [diff] [review]
Allow opening of file-URLs attached to tasks
Review of attachment 8843381 [details] [diff] [review]:
-----------------------------------------------------------------
Sorry for the delay in reviewing. To accept a patch this must be an applicable patch to our repository comm-central and not the packaged xpi. Can you provide such an patch, please?
Apart from that, see the comment below.
Philipp, do you have any objections to include the file handler protocol for this?
::: lightning-4.7.4-sm+tb-linux.xpi_FILES/chrome/calendar/content/calendar/calApplicationUtils.js
@@ +22,5 @@
> // 0. Prevent people from trying to launch URLs such as javascript:foo();
> // by only allowing URLs starting with http or https.
> // XXX: We likely will want to do this using nsIURLs in the future to
> // prevent sneaky nasty escaping issues, but this is fine for now.
> + if (!url.startsWith("http") && !url.startsWith("file")) {
Can you make this
if (!(url.startsWith("http") || url.startsWith("file:\\"))) {
instead please?
Attachment #8843381 -
Flags: review?(makemyday) → feedback+
Updated•8 years ago
|
Flags: needinfo?(philipp)
Updated•5 years ago
|
Assignee: Johannes.mozdev → nobody
Status: UNCONFIRMED → NEW
Ever confirmed: true
Updated•4 years ago
|
Type: defect → enhancement
Component: Tasks → General
Summary: Attached file-link to task won't open: "Only http:// and https:// URLs are valid" → Attached file-link to event/task won't open: "Only http:// and https:// URLs are valid"
Comment 4•3 years ago
|
||
Related to bug 168680
Updated•3 years ago
|
Severity: normal → S3
Updated•1 year ago
|
Attachment #9384948 -
Attachment is obsolete: true
You need to log in
before you can comment on or make changes to this bug.
Description
•