Skip to content

Instantly share code, notes, and snippets.

View robertholf's full-sized avatar
🙏
Laravel SaaS dev

Rob Bertholf robertholf

🙏
Laravel SaaS dev
View GitHub Profile
def predict_importance(page_id, wikiproject_id): --> score
def get_pageviews(page_id): --> int
def get_second_order_pageviews(page_id): --> int
def get_inlinks(page_id): --> int
def get_second_order_inlins(page_id): --> int
def get_internal_inlinks(page_id, wikiproject_id): --> int
@dotJoel
dotJoel / google-webfonts.ttf.css
Last active February 19, 2024 18:43
CSS for all of Google's TTF web fonts
@font-face {
font-family: 'ABeeZee';
font-style: normal;
font-weight: 400;
src: local('ABeeZee'), local('ABeeZee-Regular'), url(http://themes.googleusercontent.com/static/fonts/abeezee/v1/JYPhMn-3Xw-JGuyB-fEdNA.ttf) format('truetype');
}
@font-face {
font-family: 'Abel';
font-style: normal;
font-weight: 400;
@coenjacobs
coenjacobs / wc-attribute-links.php
Created May 4, 2012 14:05
Display WooCommerce product attribute archive links on product page, right below the add to cart button.
@jsundram
jsundram / cull.py
Last active April 5, 2023 15:22
Check if lat long is inside the bounds of the continental US (box model, not shape)
# http://en.wikipedia.org/wiki/Extreme_points_of_the_United_States#Westernmost
top = 49.3457868 # north lat
left = -124.7844079 # west long
right = -66.9513812 # east long
bottom = 24.7433195 # south lat
def cull(latlngs):
""" Accepts a list of lat/lng tuples.
returns the list of tuples that are within the bounding box for the US.
NB. THESE ARE NOT NECESSARILY WITHIN THE US BORDERS!