Git Product home page Git Product logo

python-searchonline's People

Contributors

naveen7892 avatar

Watchers

James Cloos avatar  avatar

python-searchonline's Issues

Starting Search Online Project

`import threading
import urllib2
import os
import ctypes

t = None

def searchforticket():
global t
url = "https://in.bookmyshow.com/buytickets/kabali-chennai/movie-chen-ET00039091-MT/20160722"
#url = "http://www.quora.com"
#run_cmd = 'start C:/Users/naveenkumar/Music/Thani_Oruvan/Aasai_Perasai-MassTamilan.com.mp3'
run_cmd = 'start '+url;
search_str = 'mayajaal,

'
search_str = search_str.lower()
search_strings = search_str.split(",")

req = urllib2.Request(url, headers={'User-Agent' : "Magic Browser"}) 
t = threading.Timer(10.0, searchforticket)
t.start();
print "Searching...",url
data = urllib2.urlopen(req).read()
data = data.lower();

i = 1;
found = False;
for search_string in search_strings:
    found = False;
    if( search_string in data):
        #ctypes.windll.user32.MessageBoxA(0, "Found search string: "+search_string, "String found "+(str(i)), 1)
        i = i + 1
        found = True;
        #os.system(run_cmd)
        #if(t.is_alive()):
            #t.cancel();            

if(found == True):
    ctypes.windll.user32.MessageBoxA(0, "Found search string: "+'-'.join(search_strings), "STRING FOUND", 1)
    os.system(run_cmd)
    if(t.is_alive()):
        t.cancel();

searchforticket();
`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.