Skip to content

Instantly share code, notes, and snippets.

View benmcnelly's full-sized avatar
🎯
Focusing

Ben McNelly benmcnelly

🎯
Focusing
View GitHub Profile
In [4]: Service.objects.all()
Out[4]: [<Service: FREE TUNES>]
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php/$1 [L]
@benmcnelly
benmcnelly / default.py
Created August 8, 2012 00:50 — forked from HansMayer/default.py
XBMC rtmpGUI plugin with multiple source lists, local source lists (file://), channel logos (<logourl>) and distinction by language
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import urllib, urllib2, cookielib
import string, os, re, time, datetime, sys
import xbmc, xbmcgui, xbmcplugin, xbmcaddon
BASE = [
'http://apps.ohlulz.com/rtmpgui/list.xml',
#'http://localhost/links.xml',
@benmcnelly
benmcnelly / default.py
Created August 8, 2012 00:48 — forked from anonymous/default.py
XBMC rtmpGUI plugin with multiple source lists, channel logos and distinction by language
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import urllib, urllib2, cookielib
import string, os, re, time, datetime, sys
import xbmc, xbmcgui, xbmcplugin, xbmcaddon
#from xml.etree import ElementTree
from elementtree import ElementTree
<style>
body {background:#333;}
#navbarbkg
{
background-image:url(images/navbar.jpg);
background-repeat:no-repeat;
width:900px;
height:47px;
}
#mobile views
def m_index(request):
events = Event.objects.all().order_by('start_date')
rs = {}
for event in events:
month = event.start_date.strftime("%B")
if rs.has_key(month):
rs[month].append(event)
else:
// this sets the background color of the master UIView (when there are no windows/tab groups on it)
Titanium.UI.setBackgroundColor('#000');
var win = Titanium.UI.createWindow({
title:'Places',
backgroundColor:'#333'
});
// Create XHR and load data
// this sets the background color of the master UIView (when there are no windows/tab groups on it)
Titanium.UI.setBackgroundColor('#000');
var win = Titanium.UI.createWindow({
title:'Places',
backgroundColor:'#333'
});
6B25FE7E52CFFBA402619997E2
@benmcnelly
benmcnelly / AndroidManifest.custom.xml
Created July 9, 2011 21:23
AndroidManifest.custom.xml >> Install Location to enable app 2 SD
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
android:installLocation="auto"
android:versionCode="2"
android:versionName="2"
package="com.whatever.whatwhatever"
>