This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import json, re, shlex, urllib.request | |
| watch = [] | |
| def getPrice(item): | |
| listings = json.loads(urllib.request.urlopen(makeUrl(item)).read().decode("utf-8"))["listinginfo"] | |
| lowest = None | |
| for id, obj in list(listings.items()): | |
| try: | |
| price = obj["converted_price"] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function shlex(str) { | |
| var args = str.split(" "); | |
| var out = []; | |
| var lookForClose = -1; | |
| var quoteOpen = false; | |
| for (var x in args) { | |
| if (args.hasOwnProperty(x)) { | |
| var arg = args[x]; | |
| var escSeq = false; | |
| for (var y in arg) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| try: | |
| import os, shutil, zipfile | |
| except ImportError as e: | |
| print("") | |
| print("Error: installation module not available:") | |
| print("{}.".format(e)) | |
| print("") | |
| quit() | |
| try: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <? | |
| class DB { | |
| private static $conn = null; | |
| public static function connect($host="localhost", $user="root", $pass=null, $db=null) { | |
| DB::$conn = mysqli_connect($host, $user, $pass, $db); | |
| } | |
| public static function insert($table, $data) { | |
| if (!DB::$conn) { | |
| DB::connect(); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <? | |
| class Debug { | |
| const log = 0; | |
| const success = 1; | |
| const warning = 2; | |
| const error = 3; | |
| private static $init = false; | |
| public static function start() { | |
| session_start(); | |
| if (!$_SESSION["debug"]) { |
NewerOlder