首页 > 代码库 > 获得淘宝的_tb_token_

获得淘宝的_tb_token_

$cookiepath = ‘cookie.txt‘;//cookie文件if(file_exists($cookiepath)){    $fp=fopen($cookiepath,"r");    while(!(feof($fp)))    {        $text=fgets($fp);        if(preg_match("/_tb_token_=(.*)(; v=0)/", $text, $matches)){            $_tb_token_ = trim($matches[1]);            break;        }    }}