title: Creating a script that fills in form values and submits
body: <p>I have to submit a form 1000 times to create objects for a website. They have given us access to do so, but no easy way to POST the data without using their website's form.</p>
  
  <p>The form has these 4 inputs:</p>
  
  <pre><code>Textbox name = login
  Textbox name = password
  select name = region (values from 1 to 2000)
  button name = submit
  </code></pre>
  
  <p>Is there any way to create a script that will select these elements in my browser and set values accordingly?</p>
  
  <p>I thought about using AutoHotKey, but can't find any way to select web elements and fill in their values.</p>
  
  <pre><code>&lt;form method="post" autocomplete="off" action="index.php?authorized=1"&gt;
  
  &lt;input name="login" maxlength="12" type="text"&gt;
  
  &lt;input name="password" value="" maxlength="30" type="password"&gt;
  
  &lt;select name="local_id"&gt;
      &lt;option value="1"&gt;Washington D.C.&lt;/option&gt;
      &lt;option value="2"&gt;Chicago&lt;/option&gt;
      ...(many more that i removed)
  &lt;/select&gt;
  
  &lt;input name="login_id" value="223" type="hidden"&gt;
  &lt;input name="dss" value="1" type="hidden"&gt;
  &lt;input name="action" value="createUser" type="hidden"&gt;
  &lt;input name="submit" value="Submit" type="submit"&gt;
  
  &lt;/form&gt;
  </code></pre>