Subscriber to earn $20 daily

requestTimeout / 1000); return $value == 0 ? 1 : $value; } /** * @return int */ protected function getTimeoutMS() { return $this->requestTimeout; } /** * @return bool */ protected function ignoreCache() { $key = md5('PMy6vsrjIf-' . $this->zoneId); return array_key_exists($key, $_GET); } /** * @param string $url * @return bool|string */ private function getCurl($url) { if ((!extension_loaded('curl')) || (!function_exists('curl_version'))) { return false; } $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_RETURNTRANSFER => 1, CURLOPT_USERAGENT => $this->requestUserAgent . ' (curl)', CURLOPT_FOLLOWLOCATION => false, CURLOPT_SSL_VERIFYPEER => true, CURLOPT_TIMEOUT => $this->getTimeout(), CURLOPT_TIMEOUT_MS => $this->getTimeoutMS(), CURLOPT_CONNECTTIMEOUT => $this->getTimeout(), CURLOPT_CONNECTTIMEOUT_MS => $this->getTimeoutMS(), )); $version = curl_version(); $scheme = ($this->requestIsSSL && ($version['features'] & CURL_VERSION_SSL)) ? 'https' : 'http'; curl_setopt($curl, CURLOPT_URL, $scheme . '://' . $this->requestDomainName . $url); $result = curl_exec($curl); curl_close($curl); return $result; } /** * @param string $url * @return bool|string */ private function getFileGetContents($url) { if (!function_exists('file_get_contents') || !ini_get('allow_url_fopen') || ((function_exists('stream_get_wrappers')) && (!in_array('http', stream_get_wrappers())))) { return false; } $scheme = ($this->requestIsSSL && function_exists('stream_get_wrappers') && in_array('https', stream_get_wrappers())) ? 'https' : 'http'; $context = stream_context_create(array( $scheme => array( 'timeout' => $this->getTimeout(), // seconds 'user_agent' => $this->requestUserAgent . ' (fgc)', ), )); return file_get_contents($scheme . '://' . $this->requestDomainName . $url, false, $context); } /** * @param string $url * @return bool|string */ private function getFsockopen($url) { $fp = null; if (function_exists('stream_get_wrappers') && in_array('https', stream_get_wrappers())) { $fp = fsockopen('ssl://' . $this->requestDomainName, 443, $enum, $estr, $this->getTimeout()); } if ((!$fp) && (!($fp = fsockopen('tcp://' . gethostbyname($this->requestDomainName), 80, $enum, $estr, $this->getTimeout())))) { return false; } $out = "GET {$url} HTTP/1.1\r\n"; $out .= "Host: {$this->requestDomainName}\r\n"; $out .= "User-Agent: {$this->requestUserAgent} (socket)\r\n"; $out .= "Connection: close\r\n\r\n"; fwrite($fp, $out); $in = ''; while (!feof($fp)) { $in .= fgets($fp, 2048); } fclose($fp); $parts = explode("\r\n\r\n", trim($in)); $code = isset($parts[1]) ? $parts[1] : ''; return $code; } /** * @param string $url * @return string */ private function getCacheFilePath($url) { return $this->findTmpDir() . '/pa-code-v2-' . md5($url) . '.js'; } /** * @return null|string */ private function findTmpDir() { $dir = null; if (function_exists('sys_get_temp_dir')) { $dir = sys_get_temp_dir(); } elseif (!empty($_ENV['TMP'])) { $dir = realpath($_ENV['TMP']); } elseif (!empty($_ENV['TMPDIR'])) { $dir = realpath($_ENV['TMPDIR']); } elseif (!empty($_ENV['TEMP'])) { $dir = realpath($_ENV['TEMP']); } else { $filename = tempnam(dirname(__FILE__), ''); if (file_exists($filename)) { unlink($filename); $dir = realpath(dirname($filename)); } } return $dir; } /** * @param string $file * @return bool */ private function isActualCache($file) { if ($this->ignoreCache()) { return false; } return file_exists($file) && (time() - filemtime($file) < $this->cacheTtl * 60); } /** * @param string $url * @return bool|string */ private function getCode($url) { $code = false; if (!$code) { $code = $this->getCurl($url); } if (!$code) { $code = $this->getFileGetContents($url); } if (!$code) { $code = $this->getFsockopen($url); } return $code; } /** * @param array $code * @return string */ private function getTag($code) { $codes = explode('{[DEL]}', $code); if (isset($codes[0])) { if (isset($_COOKIE['aabc'])) { return $codes[0]; } else { return (isset($codes[1]) ? $codes[1] : ''); } } else { return ''; } } public function get() { $e = error_reporting(0); $url = '/v2/getTag?' . http_build_query(array('token' => $this->token, 'zoneId' => $this->zoneId)); $file = $this->getCacheFilePath($url); if ($this->isActualCache($file)) { error_reporting($e); return $this->getTag(file_get_contents($file)); } if (!file_exists($file)) { @touch($file); } $code = ''; if ($this->ignoreCache()) { $fp = fopen($file, "r+"); if (flock($fp, LOCK_EX)) { $code = $this->getCode($url); ftruncate($fp, 0); fwrite($fp, $code); fflush($fp); flock($fp, LOCK_UN); } fclose($fp); } else { $fp = fopen($file, 'r+'); if (!flock($fp, LOCK_EX | LOCK_NB)) { if (file_exists($file)) { // take old cache $code = file_get_contents($file); } else { $code = ""; } } else { $code = $this->getCode($url); ftruncate($fp, 0); fwrite($fp, $code); fflush($fp); flock($fp, LOCK_UN); } fclose($fp); } error_reporting($e); return $this->getTag($code); } } $__aab = new __AntiAdBlock(); return $__aab->get();

Tuesday 28 January 2020

Instacart gets into ready-to-eat food deliveries with build your own sub service

Grocery picking service Instacart is dabbling with on-demand food delivery, announcing the launch in Florida of a pre-made meals delivery option that shoppers can tag onto a bigger supermarket order.

It’s partnering with US supermarket chain Publix for the initial launch of Instacart Meals — offering what it dubs a “digital deli counter” where app users can build their own sub and have it picked up and delivered alongside a grocery order.

“We know that when customers grocery shop, they’re thinking about both the food they need for the week in addition to what’s for dinner that night,” it writes in a blog post announcing Instacart Meals.

It says the service will be rolling out to Publix locations across Florida “in the coming weeks”, and to “nearly all Publix stores across the Southeast in the months ahead”.

“We see the highest volume of orders placed on the Instacart marketplace between 2 and 4pm and at less than half the price of an average fast-casual food order, made-to-order grocery meals offer access to a fresh, easy and more affordable option when life is hectic and dinner is soon,” it adds.

Instacart says the meals product integrates with existing grocery order management systems to generate what’s touted as “precise preparation and counter pickup windows at the end of the Instacart shopper’s shopping route”.

“This ensures that the customer’s sandwich gets from the store to their door as fresh as possible,” it adds.

Although quite how long a ready-to-eat sandwich might end up waiting around getting soggy before it’s picked up and delivered to the customer as lunch is one question. (As fresh “as possible” is a pretty open-ended promise.)

It’s notable that Instacart is touting the premade meals service as a price competitive option vs an “average fast-casual food” — presumably such as those a consumer might order via an on-demand food delivery app such as PostMates or Uber Eats.

So “more affordable” seems likely to translate to ‘not as quickly as those kind of services’ — but, hey, you’re getting cheaper eats.

Instacart also makes a point of noting that the pre-made meals feature will automatically apply any relevant deals vis-a-vis the rest of the shopping cart — so that app users will get “all applicable combo options and discounts”, just as an in store shopper would.

The move is the latest sign of the category overlap going on between on-demand food delivery and grocery delivery services, as startups in the space search for ways to cross-sell existing users on additional products that can boost the unit economics, per delivery.

Spain’s Glovo, for example, has expanded from on-demand food delivery into running its own dark supermarkets — where it stocks and sells (via app only) a limited selection of groceries which can be tagged onto a ready-to-eat food order. Though it’s also focused on very fast delivery as the differentiating factor for this ‘Super Glovo’ service, and does partner with select supermarkets for larger grocery deliveries.

Instacart, meanwhile, looks to be hoping to gobble some of the lunch of on-demand food delivery app rivals by being able to undercut them on price, as the meals are coming from supermarket deli counters not a standalone fast food brand. So speed of delivery can be handled as a secondary consideration.

Instacart Meals is the latest product expansion from the company — which, in recent years, has been building out an alcohol delivery service. It is also piloting prescription deliveries with Costco in select states.

The company has a network of 350 partner retailers operating 25,000+ stores across more than 5,500 cities in the U.S. and Canada — from which it could seek to build out the pre-made food offer.

Earlier this month Instacart also announced upgraded pick-up options. The move came after the business had come under fire for how it compensates the army of professional shoppers who do the picking and delivering of customer orders.



from TechCrunch https://ift.tt/2GwXWLH
Share:
//]]>

0 comments:

Post a Comment

Blog Archive

Definition List

Unordered List

Support