src/Lcrawl.php
public function getCookie($forceRefresh = false)
    {
        $cacheKey = $this->cachePrefix . $this->stu_id;
        $cached = $this->getCache()->fetch($cacheKey);
        if ($forceRefresh || empty($cached)) {
            $jar = $this->login();
            //Cache the cookieJar 3000 s.
            $this->getCache()->save($cacheKey, serialize($jar), 3000);
            return $jar;
        }
        return unserialize($cached);
    }
public function getCookie($forceRefresh = false)
    {
        $cacheKey = $this->cachePrefix . $this->stu_id;
        $cached = $this->getCache()->fetch($cacheKey);
        if ($forceRefresh || empty($cached)) {
            $jar = $this->login();
            //Cache the cookieJar 3000 s.
            $this->getCache()->save($cacheKey, serialize($jar), 3000);
            return $jar;
        }
        return unserialize($cached);
    }
public function getCookie ( $ forceRefresh = false ) { $ cacheKey = $ this -> cachePrefix . $ this -> stu_id ; $ cached = $ this -> getCache ( ) -> fetch ( $ cacheKey ) ; if ( $ forceRefresh || empty ( $ cached ) ) { $ jar = $ this -> login ( ) ; //Cache the cookieJar 3000 s. $ this -> getCache ( ) -> save ( $ cacheKey , serialize ( $ jar ) , 3000 ) ; return $ jar ; } return unserialize ( $ cached ) ; }
Get cookie from cache or login.

@param bool $forceRefresh
@return string
Get cookie from cache or login .