0

There is following js function:

function foo() 
{ 
    function bar(objArr) 
    { 
        var ts=''; 
        for (i=0; i<objArr.length; i++) 
        {
            if (objArr[i].checked == true) 
                ts +=objArr[i].value;
        } 
        return ts;
    } 

    tmb=document.getElementById('tmb');        
    x=bar(tmb.vn); 
    return x.substr(6,1); 
}

How do i match foo() function body?

clumpter
  • 1,898
  • 6
  • 27
  • 38

1 Answers1

0

Try this one:

(?<=function foo\(\))(\s|.)*
Sergio
  • 6,900
  • 5
  • 31
  • 55