title: Opening a new window with a button?
body: <p>I need to open a new window for my printing can any one let me know how to do this?</p>
  
  <p><strong>My button Click code:</strong></p>
  
  <p>My window.location works, but cant use the window.open</p>
  
  <pre><code>$('.btnFromIndexPrint').click(function () {
      if (document.URL.indexOf('index') &gt; -1) {
           // window.location = '../Print/' + $(this).attr('id');
           window.open = '../Print/' + $(this).attr('id');
      } else {
          //window.location = 'Contract/Print/' + $(this).attr('id'); //Redirect  from Index page to print action
          window.open = 'Contract/Print/' + $(this).attr('id');
      }
  
  });
  </code></pre>
  
  <p><strong>My html:</strong></p>
  
  <p>I know there is something called target ="blank" id don't think it will work though.</p>
  
  <pre><code>&lt;input type="button" value="Print" class="btnFromIndexPrint" id="@item.SalesContractId"/&gt;
  </code></pre>
  
  <hr>
  
  <p><strong>How would i open a redirect on a new page?</strong></p>
  
  <p><strong><em>Important!!!!!!!</em></strong></p>
  
  <pre><code>return RedirectToAction("Print", new { id = contractInstance.SalesContractId });
  </code></pre>