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

Javascript to Parse Reddit Comment Page for Usernames

I'm working on a bookmarklet for a Sub reddit and I'm trying to grab all the usernames on a comments page so I can parse them, then come back and update info next to them, similar to what RES does. The author of each comment has a class that is…
DiscontentDisciple
  • 466
  • 1
  • 6
  • 20
0
votes
1 answer

append parameter in URL into value of input field javascript

I'm attempting to use javascript to modify the url on page. This URL is then being passed into the bit.ly bookmarklet to be shortened. My script will append a parameter to the URL and insert it into the URL field of the bit.ly bookmarklet. If this…
0
votes
2 answers

Load a page and then execute javascript on page load

I want to make a button in NetBeans, that when clicked, will open a webpage, wait until the webpage loads, and logs in to that site. I have some code here, but I am not sure what to do after this: javascript:(function (){ …
Andrew
  • 63
  • 7
0
votes
0 answers

getSelection from iframe with bookmarklet

I'm trying to make a bookmarklet that does something with the selected text on any given website, but I'm having trouble when the selected text is in an iframe. The bookmarklet link looks like:
user888734
  • 3,797
  • 5
  • 36
  • 67
0
votes
1 answer

Javascript Bookmarklet Works in Chrome/Safari but not Firefox/IE

I have a JavaScript bookmarklet that is working fine in Chrome (v21) and Safari (v6) but when I try to use it in Firefox (v14) or IE (v9) and I get a page that just says: [object HTMLScriptElement] The bookmarklet is this (all the PHP statement at…
Nick
  • 3,172
  • 3
  • 37
  • 49
0
votes
0 answers

emacs org-protocol invocation through javascript bookmarklet in chrome

Setup Cygwin Emacs, and I have a partially working setup with org-protocol. Org-protocol is a way to capture information from the browser and pass it to Emacs. I used a Windows 7 registry modification to add org-protocol to the list of known…
assem
  • 2,077
  • 1
  • 19
  • 24
0
votes
1 answer

replace bookmarklet, with slashes

I am building a bookmarklet to replace facebook.com/ with rillist.com/?id= what i'm using now is: javascript: (function() { window.location=window.location.toString().replace(/facebook.com/,'rillist.com\?id='); })() but that…
0
votes
1 answer

create iframe on https sites

I am working on creating a bookmarklet. Basically it gets a piece of javascript code from the server and create a iframe into sites that are from different domain. It works fine on http sites, but it seems to be blocked by https sites, is there any…
0
votes
2 answers

Using @import and @font-face in a bookmarklet (works in Chrome, but not in Firefox)

I made a very simple straight forward bookmarklet to test an open web font we're developing. It works like a charm in Chrome but fails in Firefox, any tips on how can I make it work cross-browser (I'm a real JS novice, mainly copy pasting and then…
Mushon
  • 61
  • 8
0
votes
1 answer

convert jquery greybox into favelet

Hi anyone can help me with converting this into a bookmarklet to load an external site in a iframe inside an overlay like how it is done on http://jquery.com/demo/grey/ thnx
anil
0
votes
1 answer

jquery play sound when bookmarklet is released

I have a bookmarklet and I would like to play a sound when a user releases it on the bookmark bar. This is the code i have.
0
votes
3 answers

prevent function onclick but keeping it in the code | bookmarklet

I have a bookmarklet I want people to drag to bookmarks bar. The hings is I'd like to prevent the function is fired if accidentally the bookmarklet is clicked in the web page. How can I do so? Thanks
slwr
  • 1,105
  • 6
  • 16
  • 35
0
votes
1 answer

javascript bookmark to render code

I recently learned in the chat section that if you use a bookmark you can render LaTeX: http://meta.math.stackexchange.com/a/3297 The stackexchange sites all render code like this. Anything in between `` gets rendered as code. I find this feature…
jmlopez
  • 4,853
  • 4
  • 40
  • 74
0
votes
2 answers

Using JS setTimeout in a bookmarklet

I am trying to run some JS code in a bookmarklet in firefox. Here's some basic code to prove the point: window.setTimeout( function() {alert('i ran');}, 1000 ); when I run code with setTimeout in it, I get the whole page replaced by the counter…
0
votes
4 answers

How can I append this text instead of replacing it?

I have a bookmarklet: var b=document.getElementsByClassName('textinput')[0]; b.value=' (Christiansburg)'; var f=document.createEvent("HTMLEvents"); f.initEvent('change',true,true); b.dispatchEvent(f); void(0); This replaces the content (if any) of…
aslum
  • 11,774
  • 16
  • 49
  • 70