iMacros使用EVAL提取

时间:2015-11-19 20:11:09

标签: javascript copy extract paste imacros

我想更改它以使其正常工作

code+="TAG POS=1 TYPE=SPAN ATTR=TXT:* EXTRACT=TXT \n";
        code+=  'SET !VAR1 EVAL("var x=\'{{!EXTRACT}}\'; x;")' + "\n";

我想要这样

code+="TAG POS=1 TYPE=SPAN ATTR=TXT:* EXTRACT=TXT \n";
        code+=  'SET !VAR1 EVAL("var x=\'{{!EXTRACT}}\'; x;")' + "\n";
if (var1)>10{`code+="TAB CLOSEALLOTHERS\n";
}else{
code+="TAB OPEN\n";
}

请帮帮我 帮助我

1 个答案:

答案 0 :(得分:0)

尝试如下:

// here your iimPlayCode(code); or iimPlay(code);
if (parseInt(iimGetExtract()) > 10)
    iimPlayCode("TAB CLOSEALLOTHERS");
else
    iimPlayCode("TAB OPEN");