Skip to content
This repository has been archived by the owner. It is now read-only.
master
Switch branches/tags
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
App
 
 
 
 
 
 
 
 

README.md

SPES-PE

Automatic Event Uploader for Stanley Park Ecology Society

alt text

What you need to install

How to start

  • (Windows) Double click on start.bat
  • (Mac/Linux) navigate inside the app folder , type node app.js in terminal and go to localhost:8000 on your browser

How to add more websites

STEP 1: Add website name to the drop down menue on website

<option value="funcName">New Website Name</option>

STEP 2: Add new function to python script

def funcName(info,handleCount):
      try:
         driver.execute_script('''window.open("http://website.com","_blank");''')
         driver.switch_to.window(driver.window_handles[handleCount])
         ## Scrape website here
      except:
          websites["unsuccessful"].append("Website Name")
      else:
          websites["successful"].append("Website Name")
        functions = {
              "Eventful": eventful,
              "Youth Core": youthCore,
              "Planet Friendly":planetFriendly,
              "Value of options field in html page" : funcName
              }

STEP 3 : Celebrate the addition of the new function 💥

Things to note ,
  • Follow the exact function pattern provided
  • Make sure that the function key in the function's dictionary matches the value in the options tag

About

Automatic Event Uploader for Stanley Park Ecology Society

Resources

License

Packages

No packages published