greasemonkey

Choosing and activating the right controls on an AJAX-driven site

偶尔善良 提交于 2019-11-25 22:18:18
问题 So, I am trying to make it where every time I visit any nike.com sneaker page (without the HTML link), it automatically picks my shoe size, adds it to the cart, and checks out for me. I am currently trying to use this script (below), but every time I go to the sneaker page, it does not properly add the shoe size I want, but just goes straight to checkout with nothing in my cart. I\'m told that I need to match the code to the actual page HTML, but I don\'t know how to do that. Please help. //

window.close and self.close do not close the window in Chrome

若如初见. 提交于 2019-11-25 21:41:55
问题 The issue is that when I invoke window.close() or self.close() it doesn\'t close the window. Now there seems to be a belief that in Chrome you can\'t close by script any window that is not script created. That is patently false but regardless it is supposed to still do it, even if it requires to pop up an alert to confirm. These are not happening. So does anyone have real, functional and proven method of closing a window using something like javascript:window.close() or javascript:self.close(

Get image data url in JavaScript?

自作多情 提交于 2019-11-25 21:40:57
问题 I have a regular HTML page with some images (just regular <img /> HTML tags). I\'d like to get their content, base64 encoded preferably, without the need to redownload the image (ie. it\'s already loaded by the browser, so now I want the content). I\'d love to achieve that with Greasemonkey and Firefox. 回答1: Note: This only works if the image is from the same domain as the page, or has the crossOrigin="anonymous" attribute and the server supports CORS. It's also not going to give you the