title: Selenium Scroll down on Newly Opened Body
body: <p>I am working with Selenium python, and would like to scroll down on a page after clicking an element. Clicking the element gives a pop-up menu, and then when I try some scrolling methods they scroll on the original page.</p>
  
  <p>I have selected the body of the new element that has appeared and tried this: </p>
  
  <pre><code>from selenium import webdriver
  from selenium import Keys
  driver = webdriver.get(url)
  button = driver.find_element_by_xpath(pathto)
  button.click()
  body = driver.find_element_by_css('body')
  body.send_keys(Keys.PAGE_DOWN)
  </code></pre>
  
  <p>This does not actually do anything as is. However, if I first manually click on the new popup element before doing <code>body.send_keys(Keys.PAGE_DOWN)</code>, it does scroll.
  One way I have resolved this is using <code>ActionChains</code> to right click on the body before scrolling down. Directly using <code>.click()</code> on the body does not work as it clicks a link in the body.</p>
  
  <p>Are there any better ways to do this? In particular, I am somewhat afraid that the right click menu that opens up when I use my current method may mess with the rest of the scraping. Is there at least a method to guarantee that it does not interfere? Another solution could be somehow "selecting" or clicking on the body element within selenium, so are there any suggestions for this?</p>