We are showing you a translated content by identified your browser.
I will optimize the code if I'm free.
Step
-
Open Website:JD after-comment
-
Login to jd
-
Copy codes below to Development Console as previous post.
Unoptimized code
var time;
function a() {
var close = document.getElementsByClassName('btn-9');
if (close.length > 0) {
close[0].click()
var imgs = document.getElementsByName('imgs1')[0];
if (imgs != null) {
imgs.value = "//img30.360buyimg.com/shaidan/jfs/t6565/276/1439852732/41507/d7dc6d5e/59522c69N31c33f50.jpg";
var submit = document.getElementsByClassName('btn-5 mr10 setcomment')[0];
submit.click();
time = setTimeout('a()', 5000)
}
} else {
clearTimeout(time);
}
};
a();