From Evernote: |
python, ajax |
opener = urllib2.build_opener()
header = {'User-Agent':USER_AGENT,
'X-Requested-With':'XMLHttpRequest',
'Referer':发出 ajax 访问的页面的 url}
request = urllib2.Request(url,None,header)
page = opener.open(request).read()
Accept application/json, text/javascript, */*
Accept-Encoding gzip, deflate
Accept-Language en-US,en;q=0.5
Connection keep-alive
Cookie __utma=1.969807245.1332136632.1363074620.1363087633.5; _snma=www.suning.com%7C13321366319954164639577406%7C1332136631995%7C1363087631615%7C1363087641369%7C43%7C5; logonUserIdLastTime=apple2101%40gmail.com; nick=apple2101; WC_PERSISTENT=xw%2bWpAijt%2fF%2bDUW%2fLlBSTJIk6XA%3d%0a%3b2013%2d03%2d12+19%3a27%3a12%2e976%5f1363070404466%2d548555%5f10052; smhst=4797905a1526655a1526707a1504644a3436846; __utmz=1.1363071778.3.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); JSESSIONID=00007tdcVqwih8dRPN-WIvqKTCX:17a3mnbnj; cityId=9315; WC_SESSION_ESTABLISHED=true; WC_ACTIVEPOINTER=%2d7%2c10052; WC_USERACTIVITY_-1002=%2d1002%2c10052%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cnull%2cHfu4AyHVyTEH5%2fLoLwRp0%2frI3cWrBquyD%2fSaNhM3UZ0lBXgogKjO%2fnlhmMBqRneXWJNymkgPcFsi%0atcL%2foBOkrTxmwXKhtjFyuSGc%2bRxhyVmbWwnE2xgfEylnuINNcTRAFLJbP0f%2bnqRLzC%2faRcNAog%3d%3d; WC_GENERIC_ACTIVITYDATA=[30000005601374689%3atrue%3afalse%3a0%3axgte8CZGlUbEzv%2fAjAUk1wdSN%2bI%3d][com.ibm.commerce.context.audit.AuditContext|1363070404466%2d548555][com.ibm.commerce.store.facade.server.context.StoreGeoCodeContext|null%26null%26null%26null%26null%26null][CTXSETNAME|Store][com.ibm.commerce.context.globalization.GlobalizationContext|%2d7%26CNY%26%2d7%26CNY][com.ibm.commerce.catalog.businesscontext.CatalogContext|10051%26null%26false%26false%26false][com.suning.commerce.context.common.SNContext|9315%26%2d1%26null%2661%2e164%2e36%2e1%26null%26null%26null%26null%26null%26null%26null%26null%26null][com.ibm.commerce.context.base.BaseContext|10052%26%2d1002%26%2d1002%26%2d1][com.ibm.commerce.context.experiment.ExperimentContext|null][com.ibm.commerce.context.entitlement.EntitlementContext|10007%2610007%26null%26%2d2000%26null%26null%26null][com.ibm.commerce.giftcenter.context.GiftCenterContext|null%26null%26null]; _snmc=1; _snsr=direct%7Cdirect%7C%7C%7C; _snmb=136308763162090554%7C1363087641376%7C1363087641371%7C2; _snmp=136308764012592196; __utmb=1.2.10.1363087633; __utmc=1
Host www.suning.com
Referer http://www.suning.com/emall/prd_10052_10051_-7_4797905_.html
User-Agent Mozilla/5.0 (Windows NT 5.1; rv:19.0) Gecko/20100101 Firefox/19.0
X-Requested-With XMLHttpRequest
0 comments:
Post a Comment