title: Fairly New at Sharepoint Javascript. Need some feedback on custom function
body: <p>I built this function to find People Pickers by Field Title. Since the picker does not provide and TagName and Tile type of information and custom pages can have multiple people pickers, I used the NOBR tag which displays the title for each picker. This works flawlessly, but I think it can be sped up abit.</p>
  
  <p>Please share your thoughts. Thanks you!!</p>
  
  <pre><code>function resetPickerInput(title){
      var result="";
      var tags=document.getElementsByTagName("NOBR");
  
      var len=tags.length;
  
      for(var i=0;i&lt;len;i++){
  
          if(tags[i].innerHTML.indexOf(title)&gt;-1){
  
              var div=tags[i].parentNode.parentNode.parentNode.getElementsByTagName("DIV");
  
              var divLen=div.length;
  
              for(var j=0;j&lt;divLen;j++){
                  if(div[j].name=='upLevelDiv'){
                      result=div[j];
                      break;
                  }
              }
          }        
      }
      return result;
  }
  </code></pre>