Bookmark with javascript address in folder via 'open all' does not work
Categories
(Firefox :: Bookmarks & History, defect, P5)
Tracking
()
People
(Reporter: rschmitt, Unassigned)
Details
Attachments
(1 obsolete file)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:100.0) Gecko/20100101 Firefox/100.0
Steps to reproduce:
I have created a bookmark whose address is calculated using javascript with dynamic parameters.
Example:
javascript:(function(){function z(d){d=String(d);d.length<2&&(d="0"+d);return d}var c=new Date,b="";b+=z(c.getDate())+"-"+z(c.getMonth()+1)+"-"+c.getFullYear();location.href="https://www.trauer36.de/traueranzeigen-suche/erscheinungstag-"+b})();
This bookmark is in a subfolder.
Actual results:
If I use this bookmark (alone), it works fine.
If I say: open all bookmarks (of the subfolder), it doesn't work!
It prints out only the javascript code in the address line.
Expected results:
Opening the bookmark via 'open all bookmarks' of a folder should also work in this case in the same way as when (individually) opening the bookmark in the folder.
Comment 1•4 years ago
|
||
The Bugbug bot thinks this bug should belong to the 'Firefox::Bookmarks & History' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Comment 2•4 years ago
|
||
I can reproduce the bug, it's not a very common use-case though.
This is likely due to https://searchfox.org/mozilla-central/rev/9f95c41a962c9228f569f8a6b2c30edbb50b65ae/browser/base/content/utilityOverlay.js#555-560, for single bookmarlets we pass allowInheritPrincipal, but when opening multiple tabs through loadTabs we don't want to pass it for all the urls. There's some history in Bug 1466801.
Not sure what's the right path forward, we may optionally pass an array to loadtabs for allowInheritPrincipal (one for each uri), or allow each entry in the URLs array to optionally be an {url, allowInheritPrincipal} object and then split it later in loadTabs.
Dao, what do you think?
Updated•4 years ago
|
Updated•2 years ago
|
Updated•7 months ago
|
Description
•