From f5d42c76e60d095c9f6362d206cf256de2c8ecb7 Mon Sep 17 00:00:00 2001 From: Jayaram R Pai Date: Wed, 10 Sep 2014 14:57:59 +0530 Subject: initial commit --- .gitignore | 4 + manage.py | 10 ++ requirements.txt | 5 + scipy/__init__.py | 0 scipy/settings.py | 89 ++++++++++++ scipy/urls.py | 7 + scipy/views.py | 6 + scipy/wsgi.py | 14 ++ static/website/css/main.css | 188 ++++++++++++++++++++++++ static/website/images/facebook.png | Bin 0 -> 2198 bytes static/website/images/front.png | Bin 0 -> 664074 bytes static/website/images/googleplus.png | Bin 0 -> 1788 bytes static/website/images/jumbo_bg.jpg | Bin 0 -> 953606 bytes static/website/images/page.png | Bin 0 -> 372792 bytes static/website/images/scipy_india_logo.png | Bin 0 -> 1382 bytes static/website/images/twitter.png | Bin 0 -> 2264 bytes static/website/js/holder.js | 12 ++ static/website/templates/base.html | 106 ++++++++++++++ static/website/templates/home.html | 225 +++++++++++++++++++++++++++++ static/website/templates/page.html | 9 ++ website/__init__.py | 0 website/admin.py | 3 + website/migrations/__init__.py | 0 website/models.py | 3 + website/tests.py | 3 + website/urls.py | 6 + website/views.py | 10 ++ 27 files changed, 700 insertions(+) create mode 100644 .gitignore create mode 100644 manage.py create mode 100644 requirements.txt create mode 100644 scipy/__init__.py create mode 100644 scipy/settings.py create mode 100644 scipy/urls.py create mode 100644 scipy/views.py create mode 100644 scipy/wsgi.py create mode 100644 static/website/css/main.css create mode 100644 static/website/images/facebook.png create mode 100644 static/website/images/front.png create mode 100644 static/website/images/googleplus.png create mode 100644 static/website/images/jumbo_bg.jpg create mode 100644 static/website/images/page.png create mode 100644 static/website/images/scipy_india_logo.png create mode 100644 static/website/images/twitter.png create mode 100644 static/website/js/holder.js create mode 100755 static/website/templates/base.html create mode 100755 static/website/templates/home.html create mode 100644 static/website/templates/page.html create mode 100644 website/__init__.py create mode 100644 website/admin.py create mode 100644 website/migrations/__init__.py create mode 100644 website/models.py create mode 100644 website/tests.py create mode 100644 website/urls.py create mode 100644 website/views.py diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..cc0596f --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +*~ +*.pyc +config.py +*.swp diff --git a/manage.py b/manage.py new file mode 100644 index 0000000..054487a --- /dev/null +++ b/manage.py @@ -0,0 +1,10 @@ +#!/usr/bin/env python +import os +import sys + +if __name__ == "__main__": + os.environ.setdefault("DJANGO_SETTINGS_MODULE", "scipy.settings") + + from django.core.management import execute_from_command_line + + execute_from_command_line(sys.argv) diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..1d95a75 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,5 @@ +Django==1.7 +MySQL-python==1.2.5 +argparse==1.2.1 +distribute==0.6.24 +wsgiref==0.1.2 diff --git a/scipy/__init__.py b/scipy/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/scipy/settings.py b/scipy/settings.py new file mode 100644 index 0000000..353fa4f --- /dev/null +++ b/scipy/settings.py @@ -0,0 +1,89 @@ +""" +Django settings for scipy project. + +For more information on this file, see +https://docs.djangoproject.com/en/1.7/topics/settings/ + +For the full list of settings and their values, see +https://docs.djangoproject.com/en/1.7/ref/settings/ +""" + +# Build paths inside the project like this: os.path.join(BASE_DIR, ...) +import os +from config import * + +BASE_DIR = os.path.dirname(os.path.dirname(__file__)) + +# Quick-start development settings - unsuitable for production +# See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/ + +# SECURITY WARNING: don't run with debug turned on in production! +DEBUG = True + +TEMPLATE_DEBUG = True + +ALLOWED_HOSTS = [] + + +# Application definition + +INSTALLED_APPS = ( + 'django.contrib.admin', + 'django.contrib.auth', + 'django.contrib.contenttypes', + 'django.contrib.sessions', + 'django.contrib.messages', + 'django.contrib.staticfiles', + 'website', +) + +MIDDLEWARE_CLASSES = ( + 'django.contrib.sessions.middleware.SessionMiddleware', + 'django.middleware.common.CommonMiddleware', + 'django.middleware.csrf.CsrfViewMiddleware', + 'django.contrib.auth.middleware.AuthenticationMiddleware', + 'django.contrib.auth.middleware.SessionAuthenticationMiddleware', + 'django.contrib.messages.middleware.MessageMiddleware', + 'django.middleware.clickjacking.XFrameOptionsMiddleware', +) + +ROOT_URLCONF = 'scipy.urls' + +WSGI_APPLICATION = 'scipy.wsgi.application' + +# Database +# https://docs.djangoproject.com/en/1.7/ref/settings/#databases + +DATABASES = { + 'default': { + 'ENGINE': 'django.db.backends.mysql', + 'NAME': DB_NAME, + 'USER': DB_USER, + 'PASSWORD': DB_PASS + } +} + +# Internationalization +# https://docs.djangoproject.com/en/1.7/topics/i18n/ + +LANGUAGE_CODE = 'en-us' + +TIME_ZONE = 'Asia/Kolkata' + +USE_I18N = True + +USE_L10N = True + +USE_TZ = True + + +# Static files (CSS, JavaScript, Images) +# https://docs.djangoproject.com/en/1.7/howto/static-files/ + +STATIC_URL = '/static/' +STATICFILES_DIRS = ( + os.path.join(BASE_DIR, 'static'), +) +TEMPLATE_DIRS = ( + os.path.join(BASE_DIR, 'static'), +) diff --git a/scipy/urls.py b/scipy/urls.py new file mode 100644 index 0000000..ff46bce --- /dev/null +++ b/scipy/urls.py @@ -0,0 +1,7 @@ +from django.conf.urls import patterns, include, url +from django.contrib import admin + +urlpatterns = patterns('', + url(r'^', include('website.urls', namespace='website')), + url(r'^admin/', include(admin.site.urls)), +) diff --git a/scipy/views.py b/scipy/views.py new file mode 100644 index 0000000..9387ea1 --- /dev/null +++ b/scipy/views.py @@ -0,0 +1,6 @@ +from django.http import HttpResponse, HttpResponseRedirect +from django.core.context_processors import csrf +from django.shortcuts import render +from django.contrib.auth.models import User +from django.contrib.auth import authenticate, login, logout +from django.contrib.auth.decorators import login_required diff --git a/scipy/wsgi.py b/scipy/wsgi.py new file mode 100644 index 0000000..c70ddd1 --- /dev/null +++ b/scipy/wsgi.py @@ -0,0 +1,14 @@ +""" +WSGI config for scipy project. + +It exposes the WSGI callable as a module-level variable named ``application``. + +For more information on this file, see +https://docs.djangoproject.com/en/1.7/howto/deployment/wsgi/ +""" + +import os +os.environ.setdefault("DJANGO_SETTINGS_MODULE", "scipy.settings") + +from django.core.wsgi import get_wsgi_application +application = get_wsgi_application() diff --git a/static/website/css/main.css b/static/website/css/main.css new file mode 100644 index 0000000..dfce5e2 --- /dev/null +++ b/static/website/css/main.css @@ -0,0 +1,188 @@ +@import url(http://fonts.googleapis.com/css?family=EB+Garamond); +.clearfix { + clear: both; +} +.garmond { + font-family: 'EB Garamond', serif; +} +body { + background: #f2f2f2; +} +#page-wrapper { + width: 960px; + margin: 25px auto 10px; + padding: 0 0 35px 0; + background: #ffffff; + -webkit-box-shadow: 0 0 10px #cccccc; + -moz-box-shadow: 0 0 10px #cccccc; + -o-box-shadow: 0 0 10px #cccccc; + box-shadow: 0 0 10px #cccccc; + border-radius: 4px; + /*remove later*/ + min-height: 700px; +} +#main-nav .navbar-default { + background: #ffffff; + border: none; + margin-bottom: 0px; +} +#main-nav { + font-family: 'EB Garamond', serif; + font-weight: 15px; +} +#main-nav a { + -webkit-transition: color .5s ease-out 0s; + -moz-transition: color .5s ease-out 0s; + -o-transition: color .5s ease-out 0s; + transition: color .5s ease-out 0s; +} +#main-nav .navbar-default .navbar-nav > .active > a { + background: #ffffff; + font-weight: bold; +} +#header{ + height: 300px; + background: url("../images/jumbo_bg.jpg"); + background-attachment: fixed; + color: #ffffff; +} +#header h1, +#header h2, +#header h3, +#header h4, +#header h5, +#header h6 { + margin: 0; + padding: 0; +} +#header #stage { + position: relative; + top: 60px; + text-align: center; +} +#stage #scipy-logo, +#stage #shout, +#stage #subtle { + margin-bottom: 5px; +} +#stage #shout { + text-shadow: 0 0 3px #ffffff; +} +#stage #subtle { + font-family: 'EB Garamond', serif; +} +#stage .btn-default { + background: none; + color: #ffffff; + border: 1px solid #ffffff; + margin-right: 10px; + margin-left: 10px; +} +#stage .btn-default:hover { + background: #ffffff; + color: #4d4d4d; + border: 1px solid #4d4d4d; +} +#speakers .thumbnail:hover { + -webkit-box-shadow: 0 0 7px #cccccc; + -moz-box-shadow: 0 0 7px #cccccc; + -o-box-shadow: 0 0 7px #cccccc; + box-shadow: 0 0 7px #cccccc; +} +#footer-wrapper { + width: 960px; + margin: 0 auto 25px; + color: #737373; +} +#footer a { + color: #737373; +} +#footer a:hover { + color: #333333; +} +#social { + position: fixed; + right: 15px; + top: 50%; + -webkit-transform: translateY(-50%); + -moz-transform: translateY(-50%); + -o-transform: translateY(-50%); + transform: translateY(-50%); + background: #ffffff; + display: inline-block; + -webkit-border-radius: 5px; + -moz-border-radius: 5px; + -o-border-radius: 5px; + border-radius: 5px; + -webkit-box-shadow: 0 0 3px #cccccc; + -moz-box-shadow: 0 0 3px #cccccc; + -o-box-shadow: 0 0 3px #cccccc; + box-shadow: 0 0 3px #cccccc; +} +#social ul { + list-style-type: none; + margin: 0; + padding: 5px; +} +#social ul li { + padding: 3px 0; +} +#social img { + width: 25px; +} +#page-header { + height: 100px; + background: url("../images/jumbo_bg.jpg"); + background-attachment: fixed; + color: #ffffff; +} +#page-header #stage { + position: relative; + top: 25px; + padding: 10px; +} +#page-header #brand { + display: inline; + position: relative; + top: 3px; + left: 2px; +} +#page-header #current { + text-shadow: 0 0 2px #ffffff; +} +#page-content { + margin-top: 35px; +} +#page-content .col-md-9 { + min-height: 400px; +} +.nav-group li a { + position: relative; + display: block; + padding: 10px 15px; + margin-bottom: -1px; + background-color: #fff; + border: 1px solid #ddd; + color: #777777; +} +.nav-group li:first-child a { + border-top-left-radius: 4px; + border-top-right-radius: 4px; +} +.nav-group li:last-child a { + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; +} +.nav-group li.active a { + background: #f5f5f5; +} +@media (min-width: 979px) { + #sidebar .nav-group.affix { + width:210px !important; + top: 10px; + } +} +#page-content h2 { + /* fix first h2*/ + margin-top: 0; +} diff --git a/static/website/images/facebook.png b/static/website/images/facebook.png new file mode 100644 index 0000000..0009f04 Binary files /dev/null and b/static/website/images/facebook.png differ diff --git a/static/website/images/front.png b/static/website/images/front.png new file mode 100644 index 0000000..aae5c75 Binary files /dev/null and b/static/website/images/front.png differ diff --git a/static/website/images/googleplus.png b/static/website/images/googleplus.png new file mode 100644 index 0000000..62aa4b9 Binary files /dev/null and b/static/website/images/googleplus.png differ diff --git a/static/website/images/jumbo_bg.jpg b/static/website/images/jumbo_bg.jpg new file mode 100644 index 0000000..dbdfc3b Binary files /dev/null and b/static/website/images/jumbo_bg.jpg differ diff --git a/static/website/images/page.png b/static/website/images/page.png new file mode 100644 index 0000000..7866b8a Binary files /dev/null and b/static/website/images/page.png differ diff --git a/static/website/images/scipy_india_logo.png b/static/website/images/scipy_india_logo.png new file mode 100644 index 0000000..294d328 Binary files /dev/null and b/static/website/images/scipy_india_logo.png differ diff --git a/static/website/images/twitter.png b/static/website/images/twitter.png new file mode 100644 index 0000000..edec9ee Binary files /dev/null and b/static/website/images/twitter.png differ diff --git a/static/website/js/holder.js b/static/website/js/holder.js new file mode 100644 index 0000000..644dbf3 --- /dev/null +++ b/static/website/js/holder.js @@ -0,0 +1,12 @@ +/*! + +Holder - client side image placeholders +Version 2.4.0+bxlim +© 2014 Ivan Malopinsky - http://imsky.co + +Site: http://imsky.github.io/holder +Issues: https://github.com/imsky/holder/issues +License: http://opensource.org/licenses/MIT + +*/ +!function(e,t,r){t[e]=r}("onDomReady",this,function(e){"use strict";function t(e){if(!b){if(!a.body)return i(t);for(b=!0;e=S.shift();)i(e)}}function r(e){(y||e.type===s||a[c]===u)&&(n(),t())}function n(){y?(a[x](m,r,d),e[x](s,r,d)):(a[g](v,r),e[g](h,r))}function i(e,t){setTimeout(e,+t>=0?t:1)}function o(e){b?i(e):S.push(e)}null==document.readyState&&document.addEventListener&&(document.addEventListener("DOMContentLoaded",function E(){document.removeEventListener("DOMContentLoaded",E,!1),document.readyState="complete"},!1),document.readyState="loading");var a=e.document,l=a.documentElement,s="load",d=!1,h="on"+s,u="complete",c="readyState",f="attachEvent",g="detachEvent",p="addEventListener",m="DOMContentLoaded",v="onreadystatechange",x="removeEventListener",y=p in a,w=d,b=d,S=[];if(a[c]===u)i(t);else if(y)a[p](m,r,d),e[p](s,r,d);else{a[f](v,r),e[f](h,r);try{w=null==e.frameElement&&l}catch(C){}w&&w.doScroll&&!function k(){if(!b){try{w.doScroll("left")}catch(e){return i(k,50)}n(),t()}}()}return o.version="1.4.0",o.isReady=function(){return b},o}(this)),document.querySelectorAll||(document.querySelectorAll=function(e){var t,r=document.createElement("style"),n=[];for(document.documentElement.firstChild.appendChild(r),document._qsa=[],r.styleSheet.cssText=e+"{x-qsa:expression(document._qsa && document._qsa.push(this))}",window.scrollBy(0,0),r.parentNode.removeChild(r);document._qsa.length;)t=document._qsa.shift(),t.style.removeAttribute("x-qsa"),n.push(t);return document._qsa=null,n}),document.querySelector||(document.querySelector=function(e){var t=document.querySelectorAll(e);return t.length?t[0]:null}),document.getElementsByClassName||(document.getElementsByClassName=function(e){return e=String(e).replace(/^|\s+/g,"."),document.querySelectorAll(e)}),Object.keys||(Object.keys=function(e){if(e!==Object(e))throw TypeError("Object.keys called on non-object");var t,r=[];for(t in e)Object.prototype.hasOwnProperty.call(e,t)&&r.push(t);return r}),function(e){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";e.atob=e.atob||function(e){e=String(e);var r,n=0,i=[],o=0,a=0;if(e=e.replace(/\s/g,""),e.length%4===0&&(e=e.replace(/=+$/,"")),e.length%4===1)throw Error("InvalidCharacterError");if(/[^+/0-9A-Za-z]/.test(e))throw Error("InvalidCharacterError");for(;n>16&255)),i.push(String.fromCharCode(o>>8&255)),i.push(String.fromCharCode(255&o)),a=0,o=0),n+=1;return 12===a?(o>>=4,i.push(String.fromCharCode(255&o))):18===a&&(o>>=2,i.push(String.fromCharCode(o>>8&255)),i.push(String.fromCharCode(255&o))),i.join("")},e.btoa=e.btoa||function(e){e=String(e);var r,n,i,o,a,l,s,d=0,h=[];if(/[^\x00-\xFF]/.test(e))throw Error("InvalidCharacterError");for(;d>2,a=(3&r)<<4|n>>4,l=(15&n)<<2|i>>6,s=63&i,d===e.length+2?(l=64,s=64):d===e.length+1&&(s=64),h.push(t.charAt(o),t.charAt(a),t.charAt(l),t.charAt(s));return h.join("")}}(this),function(){function e(t,r,n){t.document;var i,o=t.currentStyle[r].match(/([\d\.]+)(%|cm|em|in|mm|pc|pt|)/)||[0,0,""],a=o[1],l=o[2];return n=n?/%|em/.test(l)&&t.parentElement?e(t.parentElement,"fontSize",null):16:n,i="fontSize"==r?n:/width/i.test(r)?t.clientWidth:t.clientHeight,"%"==l?a/100*i:"cm"==l?.3937*a*96:"em"==l?a*n:"in"==l?96*a:"mm"==l?.3937*a*96/10:"pc"==l?12*a*96/72:"pt"==l?96*a/72:a}function t(e,t){var r="border"==t?"Width":"",n=t+"Top"+r,i=t+"Right"+r,o=t+"Bottom"+r,a=t+"Left"+r;e[t]=(e[n]==e[i]&&e[n]==e[o]&&e[n]==e[a]?[e[n]]:e[n]==e[o]&&e[a]==e[i]?[e[n],e[i]]:e[a]==e[i]?[e[n],e[i],e[o]]:[e[n],e[i],e[o],e[a]]).join(" ")}function r(r){var n,i=this,o=r.currentStyle,a=e(r,"fontSize"),l=function(e){return"-"+e.toLowerCase()};for(n in o)if(Array.prototype.push.call(i,"styleFloat"==n?"float":n.replace(/[A-Z]/,l)),"width"==n)i[n]=r.offsetWidth+"px";else if("height"==n)i[n]=r.offsetHeight+"px";else if("styleFloat"==n)i.float=o[n];else if(/margin.|padding.|border.+W/.test(n)&&"auto"!=i[n])i[n]=Math.round(e(r,n,a))+"px";else if(/^outline/.test(n))try{i[n]=o[n]}catch(s){i.outlineColor=o.color,i.outlineStyle=i.outlineStyle||"none",i.outlineWidth=i.outlineWidth||"0px",i.outline=[i.outlineColor,i.outlineWidth,i.outlineStyle].join(" ")}else i[n]=o[n];t(i,"margin"),t(i,"padding"),t(i,"border"),i.fontSize=Math.round(a)+"px"}window.getComputedStyle||(r.prototype={constructor:r,getPropertyPriority:function(){throw new Error("NotSupportedError: DOM Exception 9")},getPropertyValue:function(e){return this[e.replace(/-\w/g,function(e){return e[1].toUpperCase()})]},item:function(e){return this[e]},removeProperty:function(){throw new Error("NoModificationAllowedError: DOM Exception 7")},setProperty:function(){throw new Error("NoModificationAllowedError: DOM Exception 7")},getPropertyCSSValue:function(){throw new Error("NotSupportedError: DOM Exception 9")}},window.getComputedStyle=Window.prototype.getComputedStyle=function(e){return new r(e)})}(),Object.prototype.hasOwnProperty||(Object.prototype.hasOwnProperty=function(e){var t=this.__proto__||this.constructor.prototype;return e in this&&(!(e in t)||t[e]!==this[e])}),function(e,t){e.augment=t()}(this,function(){"use strict";var e=function(){},t=Array.prototype.slice,r=function(r,n){var i=e.prototype="function"==typeof r?r.prototype:r,o=new e,a=n.apply(o,t.call(arguments,2).concat(i));if("object"==typeof a)for(var l in a)o[l]=a[l];if(!o.hasOwnProperty("constructor"))return o;var s=o.constructor;return s.prototype=o,s};return r.defclass=function(e){var t=e.constructor;return t.prototype=e,t},r.extend=function(e,t){return r(e,function(e){return this.uber=e,t})},r}),function(e,t){function r(e,t,r,o){var a=n(r.substr(r.lastIndexOf(e.domain)),e);a&&i(null,o,a,t)}function n(e,t){for(var r={theme:p(A.settings.themes.gray,null),stylesheets:t.stylesheets,holderURL:[]},n=!1,i=String.fromCharCode(11),o=e.replace(/([^\\])\//g,"$1"+i).split(i),a=/%[0-9a-f]{2}/gi,l=o.length,s=0;l>s;s++){var d=o[s];if(d.match(a))try{d=decodeURIComponent(d)}catch(h){d=o[s]}var u=!1;if(A.flags.dimensions.match(d))n=!0,r.dimensions=A.flags.dimensions.output(d),u=!0;else if(A.flags.fluid.match(d))n=!0,r.dimensions=A.flags.fluid.output(d),r.fluid=!0,u=!0;else if(A.flags.textmode.match(d))r.textmode=A.flags.textmode.output(d),u=!0;else if(A.flags.colors.match(d)){var c=A.flags.colors.output(d);r.theme=p(r.theme,c),u=!0}else if(t.themes[d])t.themes.hasOwnProperty(d)&&(r.theme=p(t.themes[d],null)),u=!0;else if(A.flags.font.match(d))r.font=A.flags.font.output(d),u=!0;else if(A.flags.auto.match(d))r.auto=!0,u=!0;else if(A.flags.text.match(d))r.text=A.flags.text.output(d),u=!0;else if(A.flags.random.match(d)){null==A.vars.cache.themeKeys&&(A.vars.cache.themeKeys=Object.keys(t.themes));var f=A.vars.cache.themeKeys[0|Math.random()*A.vars.cache.themeKeys.length];r.theme=p(t.themes[f],null),u=!0}u&&r.holderURL.push(d)}return r.holderURL.unshift(t.domain),r.holderURL=r.holderURL.join("/"),n?r:!1}function i(e,t,r,n){var i=r.dimensions,a=r.theme,l=i.width+"x"+i.height;if(e=null==e?r.fluid?"fluid":"image":e,null!=r.text&&(a.text=r.text,"object"===t.nodeName.toLowerCase())){for(var d=a.text.split("\\n"),u=0;u16?a.text.substring(0,16)+"…":a.text)+" ["+l+"]":l}),"image"==e?("html"!=g.renderer&&r.auto||(t.style.width=i.width+"px",t.style.height=i.height+"px"),"html"==g.renderer?t.style.backgroundColor=a.background:(o(e,{dimensions:i,theme:a,flags:r},t,g),r.textmode&&"exact"==r.textmode&&(A.vars.resizableImages.push(t),s(t)))):"background"==e&&"html"!=g.renderer?o(e,{dimensions:i,theme:a,flags:r},t,g):"fluid"==e&&("%"==i.height.slice(-1)?t.style.height=i.height:null!=r.auto&&r.auto||(t.style.height=i.height+"px"),"%"==i.width.slice(-1)?t.style.width=i.width:null!=r.auto&&r.auto||(t.style.width=i.width+"px"),("inline"==t.style.display||""===t.style.display||"none"==t.style.display)&&(t.style.display="block"),h(t),"html"==g.renderer?t.style.backgroundColor=a.background:(A.vars.resizableImages.push(t),s(t)))}function o(e,t,r,n){function i(){var e=null;switch(n.renderer){case"canvas":e=L(s);break;case"svg":e=O(s,n);break;default:throw"Holder: invalid renderer: "+n.renderer}return e}var o=null;switch(n.renderer){case"svg":if(!A.setup.supportsSVG)return;break;case"canvas":if(!A.setup.supportsCanvas)return;break;default:return}{var l={width:t.dimensions.width,height:t.dimensions.height,theme:t.theme,flags:t.flags},s=a(l);({text:l.text,width:l.width,height:l.height,textHeight:l.font.size,font:l.font.family,fontWeight:l.font.weight,template:l.theme})}if(o=i(),null==o)throw"Holder: couldn't render placeholder";"background"==e?(r.style.backgroundImage="url("+o+")",r.style.backgroundSize=l.width+"px "+l.height+"px"):("img"===r.nodeName.toLowerCase()?c(r,{src:o}):"object"===r.nodeName.toLowerCase()&&(c(r,{data:o}),c(r,{type:"image/svg+xml"})),n.reRender&&setTimeout(function(){var e=i();if(null==e)throw"Holder: couldn't render placeholder";"img"===r.nodeName.toLowerCase()?c(r,{src:e}):"object"===r.nodeName.toLowerCase()&&(c(r,{data:e}),c(r,{type:"image/svg+xml"}))},100)),c(r,{"data-holder-rendered":!0})}function a(e){function t(e,t,r,n){t.width=r,t.height=n,e.width=Math.max(e.width,t.width),e.height+=t.height,e.add(t)}switch(e.font={family:e.theme.font?e.theme.font:"Arial, Helvetica, Open Sans, sans-serif",size:l(e.width,e.height,e.theme.size?e.theme.size:12),weight:e.theme.fontweight?e.theme.fontweight:"bold"},e.text=e.theme.text?e.theme.text:Math.floor(e.width)+"x"+Math.floor(e.height),e.flags.textmode){case"literal":e.text=e.flags.dimensions.width+"x"+e.flags.dimensions.height;break;case"exact":if(!e.flags.exactDimensions)break;e.text=Math.floor(e.flags.exactDimensions.width)+"x"+Math.floor(e.flags.exactDimensions.height)}var r=new F({width:e.width,height:e.height}),n=r.Shape,i=new n.Rect("holderBg",{fill:e.theme.background});i.resize(e.width,e.height),r.root.add(i);var o=new n.Group("holderTextGroup",{text:e.text,align:"center",font:e.font,fill:e.theme.foreground});o.moveTo(null,null,1),r.root.add(o);var a=o.textPositionData=T(r);if(!a)throw"Holder: staging fallback not supported yet.";o.properties.leading=a.boundingBox.height;var s=null,d=null;if(a.lineCount>1){var h=0,u=0,c=e.width*A.setup.lineWrapRatio,f=0;d=new n.Group("line"+f);for(var g=0;g=c||m===!0)&&(t(o,d,h,o.properties.leading),h=0,u+=o.properties.leading,f+=1,d=new n.Group("line"+f),d.y=u),m!==!0&&(s.moveTo(h,0),h+=a.spaceWidth+p.width,d.add(s))}t(o,d,h,o.properties.leading);for(var v in o.children)d=o.children[v],d.moveTo((o.width-d.width)/2,null,null);o.moveTo((e.width-o.width)/2,(e.height-o.height)/2,null),(e.height-o.height)/2<0&&o.moveTo(null,0,null)}else s=new n.Text(e.text),d=new n.Group("line0"),d.add(s),o.add(d),o.moveTo((e.width-a.boundingBox.width)/2,(e.height-a.boundingBox.height)/2,null);return r}function l(e,t,r){t=parseInt(t,10),e=parseInt(e,10);var n=Math.max(t,e),i=Math.min(t,e),o=1/12,a=Math.min(.75*i,.75*n*o);return Math.round(Math.max(r,a))}function s(e){var t;t=null==e||null==e.nodeType?A.vars.resizableImages:[e];for(var r in t)if(t.hasOwnProperty(r)){var n=t[r];if(n.holderData){var i=n.holderData.flags,a=d(n,k.invisibleErrorFn(s));if(a){if(i.fluid&&i.auto){var l=n.holderData.fluidConfig;switch(l.mode){case"width":a.height=a.width/l.ratio;break;case"height":a.width=a.height*l.ratio}}var h={dimensions:a,theme:i.theme,flags:i};i.textmode&&"exact"==i.textmode&&(i.exactDimensions=a,h.dimensions=i.dimensions),o("image",h,n,n.holderData.renderSettings)}}}}function d(e,t){var r={height:e.clientHeight,width:e.clientWidth};return r.height||r.width?(e.removeAttribute("data-holder-invisible"),r):(c(e,{"data-holder-invisible":!0}),void t.call(this,e))}function h(e){if(e.holderData){var t=d(e,k.invisibleErrorFn(h));if(t){var r=e.holderData.flags,n={fluidHeight:"%"==r.dimensions.height.slice(-1),fluidWidth:"%"==r.dimensions.width.slice(-1),mode:null,initialDimensions:t};n.fluidWidth&&!n.fluidHeight?(n.mode="width",n.ratio=n.initialDimensions.width/parseFloat(r.dimensions.height)):!n.fluidWidth&&n.fluidHeight&&(n.mode="height",n.ratio=parseFloat(r.dimensions.width)/n.initialDimensions.height),e.holderData.fluidConfig=n}}}function u(e,t){return null==t?E.createElement(e):E.createElementNS(t,e)}function c(e,t){for(var r in t)e.setAttribute(r,t[r])}function f(e,t,r){if(null==e){e=u("svg",C);var n=u("defs",C);e.appendChild(n)}return e.webkitMatchesSelector&&e.setAttribute("xmlns",C),c(e,{width:t,height:r,viewBox:"0 0 "+t+" "+r,preserveAspectRatio:"none"}),e}function g(e,r){if(t.XMLSerializer){{var n=new XMLSerializer,i="",o=r.stylesheets;e.querySelector("defs")}if(r.svgXMLStylesheet){for(var a=(new DOMParser).parseFromString("","application/xml"),l=o.length-1;l>=0;l--){var s=a.createProcessingInstruction("xml-stylesheet",'href="'+o[l]+'" rel="stylesheet"');a.insertBefore(s,a.firstChild)}var d=a.createProcessingInstruction("xml",'version="1.0" encoding="UTF-8" standalone="yes"');a.insertBefore(d,a.firstChild),a.removeChild(a.documentElement),i=n.serializeToString(a)}var h=n.serializeToString(e);return h=h.replace(/\&(\#[0-9]{2,}\;)/g,"&$1"),i+h}}function p(e,t){var r={};for(var n in e)e.hasOwnProperty(n)&&(r[n]=e[n]);if(null!=t)for(var i in t)t.hasOwnProperty(i)&&(r[i]=t[i]);return r}function m(e){var t=[];for(var r in e)e.hasOwnProperty(r)&&t.push(r+":"+e[r]);return t.join(";")}function v(e){A.vars.debounceTimer||e.call(this),A.vars.debounceTimer&&clearTimeout(A.vars.debounceTimer),A.vars.debounceTimer=setTimeout(function(){A.vars.debounceTimer=null,e.call(this)},A.setup.debounce)}function x(){v(function(){s(null)})}function y(e){var r=null;return"string"==typeof e?r=E.querySelectorAll(e):t.NodeList&&e instanceof t.NodeList?r=e:t.Node&&e instanceof t.Node?r=[e]:t.HTMLCollection&&e instanceof t.HTMLCollection?r=e:null===e&&(r=[]),r}function w(e,t){var r=new Image;r.onerror=function(){t.call(this,!1,e)},r.onload=function(){t.call(this,!0,e)},r.src=e.src}function b(e){for(var t=[],r=0,n=e.length-1;n>=0;n--)r=e[n].charCodeAt(),t.unshift(r>128?["&#",r,";"].join(""):e[n]);return t.join("")}function S(e){return e.replace(/&#(\d+);/g,function(e,t){return String.fromCharCode(t)})}var C="http://www.w3.org/2000/svg",E=t.document,k={addTheme:function(e,t){return null!=e&&null!=t&&(A.settings.themes[e]=t),delete A.vars.cache.themeKeys,this},addImage:function(e,t){var r=E.querySelectorAll(t);if(r.length)for(var n=0,i=r.length;i>n;n++){var o=u("img");c(o,{"data-src":e}),r[n].appendChild(o)}return this},run:function(e){e=e||{};var o={};A.vars.preempted=!0;var a=p(A.settings,e);o.renderer=a.renderer?a.renderer:A.setup.renderer,-1===A.setup.renderers.join(",").indexOf(o.renderer)&&(o.renderer=A.setup.supportsSVG?"svg":A.setup.supportsCanvas?"canvas":"html"),a.use_canvas?o.renderer="canvas":a.use_svg&&(o.renderer="svg");var l=y(a.images),s=y(a.bgnodes),d=y(a.stylenodes),h=y(a.objects);o.stylesheets=[],o.svgXMLStylesheet=!0,o.noFontFallback=a.noFontFallback?a.noFontFallback:!1;for(var c=0;c1){r.nodeValue="";for(var b=0;b + + + + Scipy Conf + + + + +
+
+ + +
+ +
+
+
+
+ +
+ {% block content %} + {% endblock %} +
+
+
+
+
+ +
+ + +
+
    +
  • fb
  • +
  • tw
  • +
  • gp
  • +
+
+ + + + + + diff --git a/static/website/templates/home.html b/static/website/templates/home.html new file mode 100755 index 0000000..9aaa853 --- /dev/null +++ b/static/website/templates/home.html @@ -0,0 +1,225 @@ +{% load static %} + + + + + Scipy Conf + + + + +
+
+ + +
+ +
+
+
+
+

Speakers

+
+
+
+ +
+ Nicolas Valadez (Keynote) +
+
+
+
+
+ +
+ John Jarret (Keynote) +
+
+
+
+
+ +
+ Glenn Werner +
+
+
+
+
+ +
+ Robert Ellis +
+
+
+
+
+
+
+

Conference

+
+
+

Scope of the conference

+

+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. +

+
+ + + + + + + + + + + + + + + + + + +
Dec 4thKeynoteView More
Dec 5thTutorialsView More
Dec 5thLightning TalksView More
+
+
+
+
+ News and Updates +
+
+
    +
  • + + ... + +
    +
    Media heading
    + Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. +
    +
  • +
+
    +
  • + + ... + +
    +
    Media heading
    + Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. +
    +
  • +
+
    +
  • + + ... + +
    +
    Media heading
    + Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. +
    +
  • +
+
+
+
+
+
+
+
+
+

Sponsors

+
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+
+
+
+
+
+ +
+ + +
+
    +
  • fb
  • +
  • tw
  • +
  • gp
  • +
+
+ + + + + diff --git a/static/website/templates/page.html b/static/website/templates/page.html new file mode 100644 index 0000000..9f7b37f --- /dev/null +++ b/static/website/templates/page.html @@ -0,0 +1,9 @@ +{% extends 'website/templates/base.html' %} + +{% block sidebar %} + sidebar content +{% endblock %} + +{% block content %} + main content +{% endblock %} diff --git a/website/__init__.py b/website/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/website/admin.py b/website/admin.py new file mode 100644 index 0000000..8c38f3f --- /dev/null +++ b/website/admin.py @@ -0,0 +1,3 @@ +from django.contrib import admin + +# Register your models here. diff --git a/website/migrations/__init__.py b/website/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/website/models.py b/website/models.py new file mode 100644 index 0000000..71a8362 --- /dev/null +++ b/website/models.py @@ -0,0 +1,3 @@ +from django.db import models + +# Create your models here. diff --git a/website/tests.py b/website/tests.py new file mode 100644 index 0000000..7ce503c --- /dev/null +++ b/website/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/website/urls.py b/website/urls.py new file mode 100644 index 0000000..8fe5b6c --- /dev/null +++ b/website/urls.py @@ -0,0 +1,6 @@ +from django.conf.urls import patterns, include, url + +urlpatterns = patterns('', + url(r'^$', 'website.views.home', name='home'), + url(r'^page/$', 'website.views.page', name='page'), +) diff --git a/website/views.py b/website/views.py new file mode 100644 index 0000000..5bd18c0 --- /dev/null +++ b/website/views.py @@ -0,0 +1,10 @@ +from django.http import HttpResponse, HttpResponseRedirect +from django.core.context_processors import csrf +from django.views.decorators.csrf import csrf_exempt +from django.shortcuts import render + +def home(request): + return render(request, 'website/templates/home.html') + +def page(request): + return render(request, 'website/templates/page.html') -- cgit