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
-1
votes
1 answer

Bookmark Javascript, fill value in another site

I trying do a bookmark javascript javascript:(function() ..... etc. that do this: i click to script in bookmark script grab A SITE what I am in actually and open B SITE in where fill VALUE with url of A SITE and if is possible send it with…
kofola
  • 11
-1
votes
1 answer

How to grab part of URL using bookmarklet

Currently I have this bookmarklet: javascript:currentUrl=document.location.href;document.location.assign(currentUrl+'embed'); What this does is that it grabs the current URL www.example.com/knZg_INW8fL/ and adds embed behind it so it can be…
wolnavi
  • 183
  • 1
  • 14
-1
votes
1 answer

Include JavaScript File in a Bookmarklet

I want to use jQuery in my Bookmarklet. I included the source to my bookmarklet.js into the bookmarklet, so there is no more place for the jQuery File. I've tried this to include jQuery inside the included bookmarklet.js var…
iWeb
  • 233
  • 1
  • 3
  • 8
-1
votes
1 answer

Make this google translate bookmarklet run in an iframe?

I found this google translate bookmarklet from here and I was wondering if it was possible to run this code in an iframe, on the same page, instead of a new window. javascript: var t = ((window.getSelection && window.getSelection()) ||…
David Devine
  • 27
  • 1
  • 5
-1
votes
1 answer

Keep Body while changing the title

I am working with JS bookmarklets and I am playing around withjavascript:document.title = "WHATEVAH". However, when I use that by itself, it removes all content on the page. So then I tried javascript:document.title =…
Komali
  • 77
  • 10
-1
votes
1 answer

How do I create a script that replaces part of the URL with something else when I click a bookmark?

I want to know how I can create a script that replaces "https://www." in the Reddit URL, with "ps." when I click a bookmark. Does anyone know how I can do this? My programming knowledge is pretty limited.
-1
votes
1 answer

Bookmarklet to "like" a page

I would like a javascript bookmarklet that will "click" on the facebook "like" button on my web site. Its for an automated program so it can automatically have that user like the home page of my program. Is this possible?
Seatbelt99
  • 53
  • 1
  • 7
-1
votes
3 answers

Add .click() to each item in a array

I'm trying to .click() all items in an array, how can I do this? JQuery cant be used. var information = document.getElementsByClassName("menu-list-element menu-list-element-basic clickable with-icon-left with-icon-right "); for (i = 10; i <…
A. Seidel
  • 43
  • 1
  • 1
  • 7
-1
votes
1 answer

Javascript Bookmarklet - How to add pop-up title?

I'm trying to modify this bookmarklet (from pyLoad, a download manager) so that I can change the title of the download package instead of using the same one every time. I know that's possible to add a pop-up to a bookmarklet but I really don't know…
DylanDog
  • 109
  • 8
-1
votes
1 answer

How do I create a Bookmarklet?

I want to make a bookmark that when I click it in my Favourites bar, a window.confirm will appear asking a question and if I click ok instead of cancel, it will go through the current website and look for a certain word (such as dog) which I can…
-1
votes
1 answer

How can I create a bookmarklet to manipulate this URL?

I'm trying to create a bookmarklet which will change the URL of the current page as follows: Orginal URL: http://website.com/games/game-title/lobby/lobbyID/ Edited URL: http://website.com/external/game-chooser/lobbyID/ In the original URL, "games"…
ash123
  • 3
  • 2
-1
votes
1 answer

js-xlsx Uncaught TypeError: console.log is not a function

I am using xlsx for reading Excel file. It kinda works... At least first row. I don't know what's the problem so here I am. this is my code: /* set up XMLHttpRequest */ var url = "http://localhost/test.xlsx"; var oReq = new XMLHttpRequest(); …
Thomas Kolasa
  • 104
  • 1
  • 9
-1
votes
1 answer

Trouble with javascript "prototype" in bookmark. Do I need a library?

I'm trying to use a Javascript "prototype" like the one shown here: https://stackoverflow.com/a/17306971/606539 As a test, I have the following code in a "Bookmarklet" on…
Kevin Fegan
  • 1,292
  • 1
  • 16
  • 29
-1
votes
1 answer

Save javascript and html form within a bookmark

My users select one, or multiple pages and then get a button which they can then bookmark. This would give them quick acces to the pages they selected in the form. Clicking this bookmark will open all the pages the user selected at once. Now, I have…
Wijnand M
  • 372
  • 1
  • 3
  • 12
-1
votes
2 answers

How to find all .jpg, .png and .gif and list them into a grid with JavaScript?

I would like to build a basic bookmarklet that finds all .jpg, .png and .gif images of a web page and list them into a grid. (e.g. 4 images in a row) I just found this snippet but it pushes all image no matter of the extension: var images =…
Tom
  • 5,588
  • 20
  • 77
  • 129