title: Powershell: Question regarding % (Percent sign) and how it might work in the below snippet of script
body: <p>I'm working on improving my PowerShell and I have been working on over-hauling a script but I'm still pretty green so I was hoping someone could point me in the right direction.</p>
  
  <p>I understand the <code>%</code> is ForEach-Object but this is a bit different.  If you could help me understand them in this snippet, it would be appreciated. </p>
  
  <pre><code>function Replace-StringVariables ($string, $location) {
      $string = $string.Replace("%locationID%",$location.locationID)
      $string = $string.Replace("%locationName%",$location.locationName)
      $string = $string.Replace("%locationCode%",$location.locationCode)
      $string = $string.Replace("%regionName%",$location.regionName)
      $string = $string.Replace("%regionCode%",$location.regionCode)
  }
  </code></pre>
  
  <p>So, I figured out the <code>$strong</code> confusion on this, what I'm not understanding the <code>%'s</code> before AND after some of these. This is an AD project if it helps.</p>