aboutsummaryrefslogtreecommitdiff
path: root/aux/ads1.py
diff options
context:
space:
mode:
Diffstat (limited to 'aux/ads1.py')
-rwxr-xr-xaux/ads1.py28
1 files changed, 28 insertions, 0 deletions
diff --git a/aux/ads1.py b/aux/ads1.py
new file mode 100755
index 0000000..9a35dd3
--- /dev/null
+++ b/aux/ads1.py
@@ -0,0 +1,28 @@
+#!/usr/bin/env python3
+from pyvirtualdisplay import Display
+from selenium import webdriver
+from selenium.webdriver.support.ui import WebDriverWait
+from selenium.webdriver.common.by import By
+from selenium.webdriver.support import expected_conditions as EC
+from selenium.webdriver.common.keys import Keys
+from bs4 import BeautifulSoup
+import time, json, configparser, sys, os, argparse, textwrap
+from json import JSONEncoder
+from sys import argv
+
+display = Display(visible=0, size=(1024,768))
+display.start()
+
+def find_string(instring):
+ a = ""
+ with webdriver.Firefox() as browser:
+ browser.get("https://www.southernsavers.com/publix-weekly-ad-deals/")
+ #wait = WebDriverWait(browser, 8)
+ #wait.until(EC.element_to_be_clickable((By.CLASS_NAME, "selectAllLink"))).click()
+ time.sleep(15) # wait 15 seconds for good measure
+ a = browser.page_source
+ #return browser.page_source
+ return a
+
+if __name__ == "__main__":
+ loop1()
bgstack15