title: Cannot submit a website form through Selenium
body: <p>This is the second post on Stack Overflow on my quest to access this godforsaken website: <a href="https://portal.mcpsmd.org/guardian/home.html" rel="nofollow noreferrer">https://portal.mcpsmd.org/guardian/home.html</a></p>
  
  <pre><code>import org.openqa.selenium.By;
  import org.openqa.selenium.Keys;
  import org.openqa.selenium.WebDriver;
  import org.openqa.selenium.WebElement;
  import org.openqa.selenium.htmlunit.HtmlUnitDriver;
  
  public class WebAccessor  {
      public static void main(String[] args) {
  
          WebDriver driver = new HtmlUnitDriver();
          driver.get("https://portal.mcpsmd.org/public/");
          System.out.println(driver.getCurrentUrl());
  
          // Find the text input element by its name
          WebElement username = driver.findElement(By.id("fieldAccount"));
          WebElement password = driver.findElement(By.id("fieldPassword"));
  
          // Enter something to search for
          username.sendKeys("");
          password.sendKeys("");
  
          WebElement submitBtn = driver.findElement(By.id("btn-enter"));
          submitBtn.click();
  
          System.out.println(driver.getCurrentUrl());
          driver.quit();
      }
  }
  </code></pre>
  
  <p>This code is tested and works on Facebook</p>
  
  <p>I am sure that my button is being pressed as when I click submit, the site URL changes from </p>
  
  <p><a href="https://portal.mcpsmd.org/public/" rel="nofollow noreferrer">https://portal.mcpsmd.org/public/</a>
  to
  <a href="https://portal.mcpsmd.org/guardian/home.html" rel="nofollow noreferrer">https://portal.mcpsmd.org/guardian/home.html</a></p>
  
  <p>When I type in usernames and passwords, (actual user and pass cannot be disclosed for obvious reasons), the password line actually tacks on another 20 or so characters to the end of the password field. (You can see this by typing in any random username and password and clicking submit).</p>
  
  <p>This has lead me to believe there is some sort of front-end encryption going on. Is there any feasible way to log in?</p>
  
  <p>Many thanks in advance.</p>