Skip to content

Instantly share code, notes, and snippets.

ask870

Block or report user

Report or block ask870

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@ask870
ask870 / app.py
Created May 10, 2016 — forked from vgoklani/app.py
Using Flask to output Python data to High Charts
View app.py
from flask import Flask, render_template
app = Flask(__name__)
@app.route('/')
@app.route('/index')
def index(chartID = 'chart_ID', chart_type = 'bar', chart_height = 350):
chart = {"renderTo": chartID, "type": chart_type, "height": chart_height,}
series = [{"name": 'Label1', "data": [1,2,3]}, {"name": 'Label2', "data": [4, 5, 6]}]
title = {"text": 'My Title'}
@ask870
ask870 / nginx
Last active Sep 18, 2015 — forked from vdel26/nginx
Openresty init.d script
View nginx
#!/bin/sh
#
# chkconfig: 2345 55 25
# Description: Nginx init.d script, put in /etc/init.d, chmod +x /etc/init.d/nginx
# For Debian, run: update-rc.d -f nginx defaults
# For CentOS, run: chkconfig --add nginx
#
### BEGIN INIT INFO
# Provides: nginx
# Required-Start: $all
@ask870
ask870 / bottle_example.py
Last active Aug 29, 2015 — forked from Arthraim/bottle_example.py
a python web framework bottle's example
View bottle_example.py
#coding: utf-8
from bottle import route, error, post, get, run, static_file, abort, redirect, response, request, template
@route('/')
@route('/index.html')
def index():
return '<a href="/hello">Go to Hello World page</a>'
@route('/hello')
def hello():
You can’t perform that action at this time.