title: How do I reload an ASP page with a new querystring?
body: <p>In VBScript I'm getting an error every time I run this code. I just want to reload the page if the "p" variable can't be found in the <code>querystring</code>. </p>
  
  <p>What am I doing wrong exactly?</p>
  
  <pre><code>Dim sURL            'URL of the document
  sURL = document.URL
  
  'Set page number equal to 1
  If( InStr( sUrl, "?" ) = 0 ) Then
      sURL = sURL &amp; "?p=1"
      window.location = sURL
      window.location.reload()
  End If
  </code></pre>