title: How to search for a string inside an array of strings
body: <p>After searching for an answer in other posts, I felt I have to ask this.
  I looked at <a href="https://stackoverflow.com/questions/237104/javascript-array-containsobj">How do I check if an array includes an object in JavaScript?</a>
  and <a href="https://stackoverflow.com/questions/143847/best-way-to-find-an-item-in-a-javascript-array">Best way to find if an item is in a JavaScript array?</a> and couldn't get the code there to work.</p>
  
  <p>I am capturing an html embed code into an array, so each item is a line of html code.</p>
  
  <p>for example:  </p>
  
  <pre><code>i[0]='&lt;param name=\"bgcolor\" value=\"#FFFFFF\" /&gt;'
  i[1]='&lt;param name=\"width" value=\"640\" /&gt;'
  i[2]='&lt;param name=\"height\" value=\"360\" /&gt;'   
  i[3]='more html code' 
  </code></pre>
  
  <p>I want to search this array and find the line where the word 'height' is.</p>
  
  <p>So ideally, I'd like to write a function that returns the index of the item where 'height' appears.</p>
  
  <p>Fortunately, there are no duplicates in this array, so there's only one occurrence.</p>
  
  <p>with simple object search I get 'false' returns.</p>
  
  <p>Any idea?</p>