I have written a code that visits a URL using pycurl. I have tor enabled. The URL gets redirected to some other url.
Below is the code.
import pycurl
curl = pycurl.Curl()
curl.setopt(pycurl.URL, URL)
curl.setopt(pycurl.PROXY, '127.0.0.1')
curl.setopt(pycurl.PROXYPORT, 9050)
curl.setopt(pycurl.PROXYTYPE, pycurl.PROXYTYPE_SOCKS5_HOSTNAME)
curl.setopt(pycurl.USERAGENT, 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20100101 Firefox/8.0')
curl.perform()
It prints the expected html content. But whenever there is a visit to a URL, there is an increment to a count somewhere else.
Now, when I run the script, I get the html content, but there is no increment in the count, but when the same html output is run in some online html rendering website(htmledit.squarefree.com/ ), the count is incremented.
Any help to increment the count automatically, using the script itself?
Thanks.