Questions tagged [bookmarklet]

A bookmarklet is a browser bookmark for a URL using the 'javascript:' protocol. The 'javascript:' prefix is followed by a snippet of JavaScript code. When invoked, instead of navigating to a new page, the script is executed within the context of the current page.

A bookmarklet is a browser bookmark for a URL using the javascript: protocol. The javascript: prefix is followed by a snippet of JavaScript code. When invoked, instead of navigating to a new page, the script is executed within the context of the current page.

1355 questions
0
votes
1 answer

How-to change the title of the new window?

I am hacking the Google bookmarks bookmarklet to make it suit for a new purpose. The end-goal is to convert songs from youtube straight to mp3s, with the help of a 3rd party website. It's all ready pretty awesome. xD xD However, when I want to…
0
votes
1 answer

How do I detect the Google+ "share task complete" in Javascript and close Chrome Bookmarklet?

I'm using a bookmarklet that lets me share the current URL on Google Plus. Here's the JavaScript: javascript:(function(){var w=480;var h=380;var x=Number((window.screen.width-w)/2); var…
Aditya M P
  • 5,127
  • 7
  • 41
  • 72
-1
votes
2 answers

How can I use a bookmarklet to get an innerText from an external domain iframe? (x-origin errors)

I'm trying to use a bookmarlet to get a value from an iframe, which is loaded from another domain. I'm getting x-origin errors, but I don't need to communicate "between" the frames, I just need to read data from the iframe, like I would from the…
-1
votes
1 answer

A bookmarklet to customise Google Meet layout

I am using Google Meet for presentations from my Surface tablet. What I do is creating a meeting with the tablet and the desktop PC attached to the projector, and then sharing the tablet screen. It is time-consuming and boring to setup Google Meet…
antonio
  • 10,629
  • 13
  • 68
  • 136
-1
votes
1 answer

Why replacing '%20 ' fails in bookmarlet?

If I run this code in a JS fiddle, everything works as expected : let s = '%s'; let a = 'a%20b'; let b = 'a b'; a = a.replace(/%20/g, ' '); alert(a); b = encodeURIComponent(b); b = b.replace(/%20/g, ' '); alert(b); It returns a b a b But if I run…
CurioUser
  • 3
  • 3
-1
votes
1 answer

How to add a delay to a function in a single line for a bookmarklet

I have an issue, I need to delay a function in a bookmarklet, but im unsure how, since most delaying functions require more than one line of code javascript:var result = confirm("Attempt to perform function"); if(result) while (true) {…
-1
votes
1 answer

Using JavaScript in Browser's Bookmarklet to Edit the URL with Regex

So I know it's possible to run JavaScript by storing them in the browser's bookmark (aka. bookmarklet), but I'm not sure if it's possible to use bookmarklet to auto-edit the current URL (and then bring you to the new URL). What I'm trying to do: In…
Wonderer
  • 19
  • 5
-1
votes
1 answer

How do I make an alert box's input change the value in localstorage?

I'm trying to make a bookmarklet that modifies the "local storage" for a game online, but I want it to question the user the amount of "coins" the user wants via an alert. This is the…
-1
votes
1 answer

How to reoder video tiles in Jitsi?

Last year, I wrote a bookmarklet that allowed to reorder Jitsi video tiles in alphabetic order. Unfortunately, the script does not seem to work with the recent Jitsi versions anymore. I have already adjusted the access to the required elements, this…
-1
votes
1 answer

Is There a Bookmarklet That Can Change Tab Favacon

Is there a bookmarklet that can change a tab favicon? I have tried google, and github. I know this may be really complicated, but is there a bookmarklet that can do that?
-1
votes
1 answer

bookmarklet to parse id in a url and reconstruct a new one

I have an evernote web url https://www.evernote.com/shard/s5/client/snv?noteGuid=18fd15e2-9581-47db-8140-0b94dc3b9f96¬eKey=6846ea69a9afa4f5 I want to convert it with javascript to a desktop app…
Justin Lin
  • 673
  • 1
  • 6
  • 15
-1
votes
1 answer

Bookmarklet for random number input between specific ranges

I am trying to create javascript bookmarklet that it can fill boxes with numbers, range between 55-99 on any random web site. I wrote this but it doesn't work as expected var min = 55; var max = 99; Math.floor(Math.random() * (max - min + 1)) +…
-1
votes
1 answer

Bookmarklet Opens Empty Window

Ok so I have a basic bookmarklet that opens remote websites. However when I try to open my local dev site it just opens to a blank page. I am assuming this has something to do with security etc. I set the bookmarklet to open one of my remote…
Payson Welch
  • 1,388
  • 2
  • 17
  • 29
-1
votes
1 answer

restrict a bookmarklet that opens a random link on page

I found this bookmarklet that opens a random link on your current page. javascript:void(window.open(document.links[Math.floor(Math.random()*document.links.length)].href,'_self')); I wanted to use this on a website, but I also wanted to restrict it…
-1
votes
2 answers

Javascript bookmarklet generates "SyntaxError: missing ) in parenthetical" error

I am stumped as to why this simple Javascript bookmarklet fails. javascript:(setInterval(function() { var element = document.getElementById("observeBtn"); if (element != null) element.click(); }, 1000);)(); The error on the browser…
lord_nimon
  • 173
  • 9