title: Selenium's Webdriver.execute_script() returns an empty list while Chrome dev tools return a populated list
body: <p>I'm trying to use Selenium's Webdriver.execute_script() to get a list of elements from Reddit's homepage. (Before you recommend PRAW: Reddit is not actually what I want to get elements from, I'm just using it as an example.) </p>
  
  <p>Even though my executed script works fine when I run it in Chrome's dev tools console, Selenium's method only returns an empty list, which should be populated with the title elements of Reddit posts.</p>
  
  <pre><code>import urllib
  from selenium import webdriver
  from BeautifulSoup import BeautifulSoup
  
  #Path to the chromedriver is definitely working fine.
  path_to_chromedriver = 'C:\Path\goes\here\chromedriver.exe'
  browser = webdriver.Chrome(executable_path = path_to_chromedriver)
  url = 'http://www.reddit.com/'
  
  browser.implicitly_wait(10)
  browser.get(url)
  
  code = 'document.getElementsByClassName("title may-blank loggedin")'
  content = browser.execute_script("return "+code)
  
  
  if len(content) == 0:
      print content
  else:
      print len(content)
  
  browser.quit()
  </code></pre>
  
  <p>I've also tried using the webdriver.set_script_timeout() and webdriver.set_page_load_timeout() methods.</p>
  
  <p>Example of the target element:</p>
  
  <pre><code>&lt;a class="title may-blank loggedin" href="/r/IAmA/comments/2necex/i_am_joel_hodgson_creator_of_mystery_science/" tabindex="1"&gt;I am Joel Hodgson, creator of Mystery Science Theater 3000, why don't you come at me?&lt;/a&gt;
  </code></pre>