[Notice] Trying to access array offset on value of type null

GET /gb/news-and-reports/news/oset-welcomes-dougie-lampkin-at-moto-gp

Line 240 in /home/osetbike/public_html/mysite/code/Site/Page.php

Source

231 	{
232 
233 		$visitor = $_SERVER['REMOTE_ADDR'];
234 
235 			$ipLite = new ip2location_lite;
236 
237 			if (!isset($_COOKIE["geolocation"])) {
238 				$ipLite->setKey('7e6adac1e161b5b5277aa7e960f5b84ab4a979674aa8ca969ce724c2cfdb1916');
239 				$visitorGeolocation = $ipLite->getCountry($visitor);
240 				if ($visitorGeolocation['statusCode'] == 'OK') {
241 					$data = base64_encode(serialize($visitorGeolocation));
242 					setcookie("geolocation", $data, time() + 3600 * 24 * 30); //set cookie for 1 month
243 				}
244 			} else {
245 				$visitorGeolocation = unserialize(base64_decode($_COOKIE["geolocation"]));
246 			}

Trace

GET /gb/news-and-reports/news/oset-welcomes-dougie-lampkin-at-moto-gp

[Notice] Trying to access array offset on value of type null

GET /gb/news-and-reports/news/oset-welcomes-dougie-lampkin-at-moto-gp

Line 253 in /home/osetbike/public_html/mysite/code/Site/Page.php

Source

244 			} else {
245 				$visitorGeolocation = unserialize(base64_decode($_COOKIE["geolocation"]));
246 			}
247 
248 			//Get errors and locations
249 			$errors = $ipLite->getError();
250 
251 			$locale = substr($this->Locale, -2);
252 
253 			if ((string)$visitorGeolocation['countryCode'] == 'UK') {
254 				(string)$visitorGeolocation['countryCode'] = 'GB';
255 			}
256 
257 			if ((string)$visitorGeolocation['countryCode'] != $locale) {
258 				return true;
259 			} else {

Trace

GET /gb/news-and-reports/news/oset-welcomes-dougie-lampkin-at-moto-gp

[Notice] Trying to access array offset on value of type null

GET /gb/news-and-reports/news/oset-welcomes-dougie-lampkin-at-moto-gp

Line 257 in /home/osetbike/public_html/mysite/code/Site/Page.php

Source

248 			//Get errors and locations
249 			$errors = $ipLite->getError();
250 
251 			$locale = substr($this->Locale, -2);
252 
253 			if ((string)$visitorGeolocation['countryCode'] == 'UK') {
254 				(string)$visitorGeolocation['countryCode'] = 'GB';
255 			}
256 
257 			if ((string)$visitorGeolocation['countryCode'] != $locale) {
258 				return true;
259 			} else {
260 				return false;
261 			}
262 
263 	}

Trace

OSET WELCOMES DOUGIE LAMPKIN AT MOTO GP - OSET Bikes

OSET WELCOMES DOUGIE LAMPKIN AT MOTO GP

OSET Bikes was delighted to welcome trials legend, Dougie Lampkin onto the stand at Moto GP this weekend.

The trials supremo demonstrated his skills to the OSET kids, who are providing a display at the blue riband event and gave them some tips for some of the bigger obstacles.  Delighted to meet one of their heroes, Dougie posed for photos and signed helmets and riding gear before heading off to wow the Silverstone crowds.

Ian Smith, founder of OSET Bikes, said: “It’s great that an event like MOTO GP welcomes a range of two-wheeled sport.  Dougie is a real figure head for trials and it’s always good to catch up.  The kids love it when he stops by, and he really adds a buzz to the OSET demo area when he’s around.”

 

 

Share: