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
#!/usr/bin/env python | |
from bottle import request, run, route, template, static_file | |
@route('/box/auth') | |
def authorize_box(): | |
code = request.query.code; | |
if(code): | |
return template(""" |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import re | |
class BanglaEncodingConverter: | |
"""Converts Bengali Text between Encodings""" | |
def replace(self, source, target, in_text): | |
"""Returns a string encoded to target_encoding from source_encoding. |
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
#include <linux/string.h> | |
#include "lcm_drv.h" | |
static LCM_UTIL_FUNCS lcm_util = {0}; | |
#define SET_RESET_PIN(v) (lcm_util.set_reset_pin((v))) | |
#define UDELAY(n) (lcm_util.udelay(n)) | |
#define MDELAY(n) (lcm_util.mdelay(n)) |
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 urllib2 | |
from BeautifulSoup import BeautifulSoup | |
def get_html(exam, year, board, roll): | |
"""Get the result page HTML output directly. | |
get_html(exam, year, board, roll)""" | |
base_url = "http://www.educationboardresults.gov.bd/regular" | |
base_index = 'index.php' |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import urllib | |
import json | |
version = "15.10" | |
arch = "i386" # i386 or amd64 | |
mirrorlist = ["http://ubuntu.mirror.mendoza-conicet.gob.ar/", "http://releases.ubuntu.unc.edu.ar/", "http://ftp.iinet.net.au/pub/ubuntu-releases/", "http://mirror.aarnet.edu.au/pub/ubuntu/releases/", "http://mirror.netspace.net.au/pub/ubuntu-releases/", "http://ubuntu.mirror.serversaustralia.com.au/ubuntu-releases/", "http://ubuntu.mirror.uber.com.au/releases/", "http://mirror.internode.on.net/pub/ubuntu/releases/", "http://ubuntu.lagis.at/releases/", "http://mirrors.ispros.com.bd/ubuntu-release/", "http://by.releases.ubuntu.com/", "http://ubuntu-releases.mirror.nucleus.be/", "http://ubuntu.mirrors.skynet.be/pub/ubuntu.com/releases/", "http://bw.releases.ubuntu.com/", "http://ubuntu.c3sl.ufpr.br/releases/", "http://mirror.globo.com/ubuntu/releases/", "http://mirror.pop-sc.rnp.br/mirror/ubuntu/", "http://ubuntu.mirror.pop-sc.rnp.br/mirror/ubuntu-releases/", "http://mirror.unesp.br/ubuntu |
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
var colors = ["#27ae60", "#3498db", "#9b59b6", "#34495e", "#d35400", "#D35400"]; //le flatui colors | |
var randomInt = function(min, max) { | |
return Math.floor(Math.random() * (max - min + 1)) + min; | |
}; | |
$(document).ready(function(){ | |
var colorint = randomInt(0,5); | |
$("body").css("background-color", colors[colorint]); | |
$(".btn-home-menu").css("color", colors[colorint]); |
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
#!/usr/bin/env python | |
#-*- coding: utf-8 -*- | |
import urllib2 | |
from BeautifulSoup import BeautifulSoup | |
def main(): | |
linkslist = getAyahLinks() | |
sura_count = 0 | |
for each_link in linkslist: |
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
from django.shortcuts import render_to_response | |
from django.template import RequestContext | |
def about(request): | |
return render_to_response("about.html", | |
{'page_title': 'About us', | |
#and other stuff | |
}, | |
RequestContext(request)) |
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
<?php | |
system("wget -q http://www.bing.com -O bing"); | |
$dump = file_get_contents("bing"); | |
system("rm bing"); | |
$chunks = explode("g_img=", $dump); | |
$temps = explode("'", $chunks[1]); | |
$url = "http://www.bing.com/".$temps[1]; | |
system ("wget -q $url -O /home/".'$USER'."/Pictures/bing.jpg"); | |
system ("gsettings set org.gnome.desktop.background picture-uri file:///home/".'$USER'."/Pictures/bing.jpg"); | |
?> |
NewerOlder