Questions tagged [ninjakit]

NinjaKit is a Safari extension that allows you to enhance the way web-pages work, by running javascript (with enhanced privileges) on websites that you specify. It is modeled after, and works similarly to, Greasemonkey.

NinjaKit is a userscript manager for the Safari browser. Userscripts are written in JavaScript, and run in every page as specified by the @include, @exclude, and @match rules.

NinjaKit was written to closely emulate Greasemonkey (the GM release of circa 2012). See for related information.

Resources:

6 questions
6
votes
1 answer

Use GM_xmlhttpRequest to POST data on Chrome?

I'm writing a user script to take an image from a page, and upload it to a server. The script works fine in FF (Greasemonkey and Scriptish), but when I use Chrome (using Tampermonkey or Ninjakit), it does not send the data, it sends the string *…
2
votes
2 answers

Using userscript GM_functions inside the page context

I want to "re-link" everything in a specific page through a XMLHTTPRequest to a local network domain. That would lead me to GM_xmlhttpRequest in GreaseMonkey/NinjaKit except that I want to run it when the link is clicked, not when the userscript…
Filipe Pina
  • 2,201
  • 23
  • 35
2
votes
0 answers

Block Gmail from stealing focus with user script

I'm trying to stop Gmail from stealing focus using a user script. I'm using NinjaKit on safari. So far I have // ==UserScript== // @name GMAIL // @namespace https://mail.google.com // @include https://mail.google.com/* //…
Alec Jacobson
  • 6,032
  • 5
  • 51
  • 88
0
votes
1 answer

Retrieving Data created by Safari Extensions

So recently Safari upgraded to Safari 12 and all extension not created through the Extensions API no longer work properly. This is troublesome for me, as I have been working on a project for the past few years that required the use an extension that…
Siggy
  • 11
  • 3
0
votes
1 answer

Safari seems to cache the page and the DOM state

I've written a Greasemonkey javascript that works fine in NinjaKit the new Safari userscript manager, but when I try and compile the same script using the Safari 5 extension builder I get some very weird behavior. The script gives the user an…
user280109
  • 1,476
  • 3
  • 16
  • 27
0
votes
2 answers

Why doesn't this Greasemonkey script work with this jQuery plugin?

I'm using NinjaKit in Safari (Same as Greasemonkey). The codes are like this // ==UserScript== // @name demo // @namespace http://dailymed.nlm.nih.gov/ // @include http://dailymed.nlm.nih.gov/dailymed/* // @require …
Hanfei Sun
  • 45,281
  • 39
  • 129
  • 237