title: How to start a Selenium Firefox web browser minimized?
body: <p>My python script is in a loop and runs every half an hour, when ever the code runs it opens Firefox browser. So if I am working/ looking at any other screen all of a sudden the browser window pops up. I want my browser to either start minimized or disappear but my code should execute </p>
  
  <pre><code>while(True):
      driver = webdriver.Firefox()
      driver.get("http://iiitb.campusmetalink.com/cml/pages/setup/ModuleHome.jsf")
      driver.find_element_by_name("recqIDId:j_id15").send_keys("IIITB")
      driver.find_element_by_name("recqIDId:j_id17").send_keys("username")
      driver.find_element_by_name("recqIDId:j_id19").send_keys("password")
      driver.find_element_by_name("recqIDId:j_id25").click()
      WebDriverWait(driver, 100)
      driver.find_element_by_xpath('//*[@id="moduleForm:j_id40_body"]/table/tbody/tr/td[2]/table/tbody/tr/td/table/tbody/tr[6]/td[2]/a').click()
      driver.find_element_by_xpath('//*[@id="scheduleForm:coltrm"]').send_keys("2016TERM2")
      driver.find_element_by_xpath('//*[@id="scheduleForm:search"]').click()
      elements = driver.find_elements_by_xpath('//*[@id="scheduleForm:svres:tb"]/tr')
      if( len(elements) &gt; 6):
          os.system("C:/wamp64/bin/php/php5.6.16/php C:/wamp64/www/srishti/space_auth/Source/Source_code/public/mail_includes.php")
      print elements
      driver.close()
      time.sleep(1800)
  </code></pre>