New Python Script & A Glitch GIF


It's been a while since I've been randomly playing around with code and formats of files, so I thought it's about time for me to do so.

I wanted to buy a LOMO, but since I believe all LOMO machines are offensively expensive, I wanted to buy it second hand. I checked a nation-wide online flea market called and found several posts but none of them was interesting to me. But I wanted to keep a track of them, so I wrote a small script that does the job for me. Instead of visiting the website all the time, I hardcoded the link of the web page to the script and it does the job for me. Here is the code:

import urllib2
file = urllib2.urlopen('')
dload =

searchString = "<strong>60</strong>"

if searchString in dload:
print "HTML File has not changed, still 60 posts."

print 'HTML File appears to have changed, please check: \n                           verkaufen/marktplatz?keyword=lomo&x=0&y=0&sort=4'

This may look silly at first, but that is only because the code is silly. Seriously, I just parse the HTML from the source, and look for a "<strong>60</strong>" which is totally arbitrary, but in this specific case it was the number of posts that are already shown. So if it changes, the code prints "HTML File appears to have changed, please check..." and that's it.

For running it, I just press Windows key + R, then type cmd and hit ENTER. Then go to Python directory and locate the script and run it. That's it. Pretty simple but that was what I needed anyway.

The other one is just a 10-minute fun, so I'll just leave it here. Because it's peanut butter jelly time.