07/25 - Wooly Wednesday!

Status
Not open for further replies.

rsclone

This is my partner Fellatio Del Toro
Banned
Joined
Dec 17, 2016
Messages
6,128
Reaction score
12,435
Points
988
no, you ate American Thai food. Health standards are a little different over there. But all joking aside it's defo worth the risk of getting the shits
oh I know...believe me I know....working in a Chinese place was quite eye opening to the cultural differences on sanitation and food safety...I've no doubt I saved lots of people from stomach issues when I started working there....lol
 

Jatis

Member
Joined
Apr 12, 2018
Messages
346
Reaction score
461
Points
263
Age
34
Gender
Male
Hey so I added:
"$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();"

to my script. How do I make this happen not when I load the HIT, but when I press a hotkey?
 

K'Lee

The Royal Taster
Contributor
Joined
Aug 6, 2016
Messages
4,769
Reaction score
8,180
Points
838
Age
56
Gender
Female
try restarting your browser?
Did that. Not sure what I didn't do right. Oh well. I'll eventually figure it out. Probably once the hits are gone. :p
 

SarahAshlee90

Well-Known Member
Crowd Pleaser
Joined
Mar 4, 2016
Messages
2,781
Reaction score
5,294
Points
963
Age
33
Gender
Female
Hey so I added:
"$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();"

to my script. How do I make this happen not when I load the HIT, but when I press a hotkey?
You added a quote in front of the first one that will break your script. Also adding the same line 3 times isn't necessary, once will do.
 

SarahAshlee90

Well-Known Member
Crowd Pleaser
Joined
Mar 4, 2016
Messages
2,781
Reaction score
5,294
Points
963
Age
33
Gender
Female
Did that. Not sure what I didn't do right. Oh well. I'll eventually figure it out. Probably once the hits are gone. :p
When you click on the Tampermonkey icon next to the omnibar, is it showing the script as running?
 

Jatis

Member
Joined
Apr 12, 2018
Messages
346
Reaction score
461
Points
263
Age
34
Gender
Male
You added a quote in front of the first one that will break your script. Also adding the same line 3 times isn't necessary, once will do.
So this is what im working with

"
// ==/UserScript==

$('input[value="NoZipper"]').click();
$('input[value="NoButtons"]').click();
$('input[value="NoHood"]').click();
$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();

so obviously it's kind of redundant because the first three get undone by the bottom three (or one if i can remove the button two but there are three clicks that need to be made)

What i want to happen is for the first three lines to happen when i load the HIT, and the second three to happen only when i press a button.
 

SarahAshlee90

Well-Known Member
Crowd Pleaser
Joined
Mar 4, 2016
Messages
2,781
Reaction score
5,294
Points
963
Age
33
Gender
Female
So this is what im working with

"
// ==/UserScript==

$('input[value="NoZipper"]').click();
$('input[value="NoButtons"]').click();
$('input[value="NoHood"]').click();
$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();
$('input[value="MoreThanOne"]').click();

so obviously it's kind of redundant because the first three get undone by the bottom three (or one if i can remove the button two but there are three clicks that need to be made)

What i want to happen is for the first three lines to happen when i load the HIT, and the second three to happen only when i press a button.
Code:
window.onkeydown = function (event) {                                    // this function triggers an event every time a keystroke is pressed
        if(event.which == 97){                                           // this branch asks if the keystroke was the keystroke that should call your code.  97 means the numpad 1 key.
                                                                         //Google javascript keycodes to figure out the rest.
// code you want to run on the keystroke event goes here       
            }
 
Last edited:

Jatis

Member
Joined
Apr 12, 2018
Messages
346
Reaction score
461
Points
263
Age
34
Gender
Male
Code:
window.onkeydown = function (event) {            // this function triggers an event every time a keystroke is pressed
        if(event.which == 97){                               //  this branch asks if the keystroke was the keystroke that should call your code.  97 means the
                                                                         //  numpad 1 key.  Google javascript keycodes to figure out the rest.
// code you want to run on the keystroke event goes here           
            }
Thank you so much that really clears things up, should be able to do hotkey inputs no problem now.

Final thing to solve is can i automate submitting return but thats such a rare use case ill sort it out after the batch is done
 
  • Like
Reactions: SarahAshlee90

Jatis

Member
Joined
Apr 12, 2018
Messages
346
Reaction score
461
Points
263
Age
34
Gender
Male
Sooo, I broke it. I'm guessing formatting?
// ==UserScript==
// Name @Name Amazon Requester Inc.- Tops
// @namespace http://tampermonkey.net/
// @version 1.0
// @description
// @author Egryan1
// @match https://s3.amazonaws.com/mturk_bulk/hits/*
// @grant GM_log
// @require http://code.jquery.com/jquery-3.1.1.min.js
// ==/UserScript==

$('input[value="NoZipper"]').click();
$('input[value="NoButtons"]').click();
$('input[value="NoHood"]').click();

window.onkeydown = function (event) {
if(event.which == 97){
$('input[value="MoreThanOne"]').click();
}

i don't know how to make my spacing show up in the forum
 
Last edited:

JenniLeigh

Batch Betta Have My Money
Contributor
Joined
Jan 12, 2016
Messages
23,084
Reaction score
46,895
Points
1,388
Location
my napping spot
Gender
Female
Title: A Survey To Gauge Your Opinions and Awareness on Home Financing (HOME OWNERS ONLY!) (140665) | Accept
Requester: cryptonaut [A2IKSF9PTILXWS] Contact
TV: No Reviews
TO: [Pay=3.40] [Fast=5.00] [Comm=0.00] [Fair=5.00] [Reviews=5] [ToS=2]
TO2: [Hrly=20.00] [Pen=0.04 days] [Res=null] [Rec=100%] [Rej=0] [ToS=0] [Brk=0]
Reward: 1.00
Duration: 3600
Available: 1
Description: This Survey is Designed To Gauge Your Opinions on Home Financing and help Americans understand their options when it comes to mortgages and refinancing. You will have to qualify for this survey which should take just a few seconds of your time. The survey should take less than a minute to complete if you qualify.
Qualifications: HIT approval rate (%) GreaterThan 98; Location EqualTo US
[tr][td]
HIT exported from Mturk Suite v2.3.7
[/td][/tr]
[tr][td][/td][/tr]
 

SarahAshlee90

Well-Known Member
Crowd Pleaser
Joined
Mar 4, 2016
Messages
2,781
Reaction score
5,294
Points
963
Age
33
Gender
Female
Sooo, I broke it. I'm guessing formatting?
// ==UserScript==
// Name @Name Amazon Requester Inc.- Tops
// @namespace http://tampermonkey.net/
// @version 1.0
// @description
// @author Egryan1
// @match https://s3.amazonaws.com/mturk_bulk/hits/*
// @grant GM_log
// @require http://code.jquery.com/jquery-3.1.1.min.js
// ==/UserScript==

$('input[value="NoZipper"]').click();
$('input[value="NoButtons"]').click();
$('input[value="NoHood"]').click();

window.onkeydown = function (event) {
if(event.which == 97){
$('input[value="MoreThanOne"]').click();
}

i don't know how to make my spacing show up in the forum
Wrap it in code tags so at name looks like
Code:
@name
and not
Name @Name
 
  • Like
Reactions: ufaastra and Jatis

Jatis

Member
Joined
Apr 12, 2018
Messages
346
Reaction score
461
Points
263
Age
34
Gender
Male
Code:
// ==UserScript==
// @name         Amazon Requester Inc.- Tops
// @namespace    http://tampermonkey.net/
// @version      1.0
// @description
// @author       Egryan1
// @match        https://s3.amazonaws.com/mturk_bulk/hits/*
// @grant         GM_log
// @require      http://code.jquery.com/jquery-3.1.1.min.js
// ==/UserScript==

$('input[value="NoZipper"]').click();
$('input[value="NoButtons"]').click();
$('input[value="NoHood"]').click();

window.onkeydown = function (event) {
            if(event.which == 97){
                $('input[value="MoreThanOne"]').click();
                            }
So when I run this nothing is selected, but if i run it without the bottom half it preselects fine.
 
Last edited:

nopoopwarez

Well-Known Member
Contributor
Joined
Sep 16, 2016
Messages
10,324
Reaction score
18,600
Points
1,238
Age
37
Gender
Male
Got one pin. Just enough to lock myself out.
 
Status
Not open for further replies.