This file contains 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 time | |
import praw | |
import pyttsx | |
__author__ = "Lyndon Armitage" | |
username = "alarmbot" | |
password = "password" | |
engine = pyttsx.init() |
This file contains 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
package com.lyndonarmitage.reddit; | |
import com.omrlnr.jreddit.submissions.Submission; | |
import com.omrlnr.jreddit.submissions.Submissions; | |
import com.omrlnr.jreddit.user.User; | |
import com.sun.speech.freetts.VoiceManager; | |
import org.joda.time.DateTime; | |
import org.joda.time.LocalDateTime; | |
import org.joda.time.LocalTime; | |
import org.joda.time.Period; |
This file contains 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 requests | |
import time | |
__author__ = "Lyndon Armitage" | |
check_interval = 60 * 1 # Every 1 min | |
interval = 60 * 1 # Interval to sleep at (can be faster than check interval) | |
last_check_time = time.clock() - check_interval | |
username = "theanchorman" | |
start_certs = 0 |
This file contains 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 requests | |
import pyttsx | |
import time | |
__author__ = 'Lyndon' | |
# SOE documentation: https://census.soe.com/ | |
# Faction IDs | |
def get_faction(id): |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Clock</title> | |
<style type="text/css"> | |
#container { | |
margin: 0 auto; | |
width: 800px; | |
text-align: center; | |
border: black dashed 1px; |
This file contains 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
/** | |
* Setup and start an analog clock using a canvas | |
* @param canvas The canvas to use | |
* @param clockWidth The width of the clock (radius*2) | |
* @author Lyndon Armitage | |
*/ | |
function setupAnalogClock(canvas, clockWidth) { | |
var ctx = canvas.getContext("2d"); | |
var centerX = canvas.width / 2; | |
var centerY = canvas.height / 2; |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Check if File is PDF on the Client Side</title> | |
</head> | |
<body> | |
<form id="uploadForm"> | |
<label>Upload a PDF: <input type="file" id="fileUpload" name="file" /></label> | |
</form> | |
<script type="text/javascript" src="js/checkPDF.js"></script> |
This file contains 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
/** | |
* Used to attach events to an element or object in a browser independent way | |
* @param element | |
* @param event | |
* @param callbackFunction | |
*/ | |
function attachEvent(element, event, callbackFunction) { | |
if(element.addEventListener) { | |
element.addEventListener(event, callbackFunction, false); | |
} |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>jQuery Viewer Example</title> | |
<style type="text/css"> | |
body { | |
background: #0000FF; | |
} | |
#container { | |
margin-left: auto; |
OlderNewer