디시 접속 - 댓글 뿌지직 - 종료 


왼쪽언어는 되는데 오른쪽 언어는 안되네요.


특히 씨샵같은경우는 재바하고 비슷하게 해놔서 아예 틀린게 뭔지 모르겠는데.. .. 


도와주세요! 


파이썬 코드

http://ideone.com/l0mqZs


import requests


roffjfl = 'programming'

qjsgh = '406537'


res = requests.get('http://gall.dcinside.com/board/lists/?id=' + roffjfl)</p><p>cookie = res.headers['set-cookie']


#CI_C값 추출.

st = cookie.find("ci_c")

ed = cookie.find(";", st)

cookie = cookie[st+5:ed];


#http 헤더

httpHeaders={"Accept": "*/*"

,"Accept-Encoding": "gzip:deflate:sdch"

,"Accept-Language":

        "ko-KR:ko;q=0.8:en-US;q=0.6:en;q=0.4"

,"Connection": "keep-alive"

,"Content-Type":

        "application/x-www-form-urlencoded; charset=UTF-8"

,"Host": "gall.dcinside.com"

,"Origin": "http://gall.dcinside.com"

,"Referer":

        "http://gall.dcinside.com/board/view/?id="+roffjfl+"&no="+qjsgh</p><p>,</p><p>        "User-Agent":

        "Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.36 (KHTML: like Gecko) Chrome/30.0.1599.101 Safari/537.36"

,"X-Requested-With": "XMLHttpRequest"}


#post데이터

post no qjsgh, memo='테스트', ci_t=cookie, name='ㅇㅇ', password='123123' )


post = requests.post('http://gall.dcinside.com/forms/comment_submit', >

print(post.text)