Beispiel #1
0
 /**
  * @return string
  */
 public function toUrl($guard = false)
 {
     if ($guard === true) {
         $this->addCSRFGuard();
     } else {
         if ($guard == self::UNIQUE_CSRF) {
             $tempGuard = self::$crossSiteGuard;
             self::$crossSiteGuard = null;
             $this->addCSRFGuard();
             self::$crossSiteGuard = $tempGuard;
         }
     }
     TamperGuard::add($this);
     $this->convertFormVarsToFlatArray();
     TamperGuard::del($this);
     if ($guard) {
         $this->delCSRFGuard();
     }
     return join('&', $this->intermediateUrlArray);
 }