This function does escape http:// and https:// in url as mod_rewrite disables requests with ://
public static encodeRefererUrl ( $url ) : encoded | ||
$url | ||
return | encoded | url |
public function setClick(Pap_Db_RawClick $click) { $this->cl = $click->getId(); $this->ba = $click->getBannerId(); $this->pb = $click->getParentBannerId(); $this->ts = $click->getDateTimestamp(); $this->rf = substr(Pap_Tracking_Request::encodeRefererUrl($click->getRefererUrl()), 0, 80); $this->ip = $click->getIp(); $this->d1 = $click->getData1(); $this->d2 = $click->getData2(); $this->ch = $click->getChannel(); }
protected function setQueryParams(Gpf_Net_Http_Request $request) { $request->addQueryParam('visitorId', $this->visitorId); $request->addQueryParam('accountId', $this->accountId); $request->addQueryParam('url', Pap_Tracking_Request::encodeRefererUrl($this->getUrl())); $request->addQueryParam('referrer', Pap_Tracking_Request::encodeRefererUrl($this->getReferrerUrl())); $request->addQueryParam('tracking', '1'); $request->addQueryParam('getParams', $this->getGetParams()->getQuery()); $request->addQueryParam('cookies', $this->getOldCookies()); $request->addQueryParam('ip', $this->getIp()); $request->addQueryParam('useragent', $this->getUserAgent()); }