Commit e8ee2978 by Calen Pennington Committed by Adam Palay

Remove news carousel and other unused pages

Remove unused course_filter page

removes university_profile urls and templates

removes all university_profile views

remove news from templates/index
parent 0d3c4499
from django.http import HttpResponse
from django.shortcuts import redirect
from mitxmako.shortcuts import render_to_string, render_to_response
__all__ = ['edge', 'event', 'landing']
......@@ -11,7 +12,7 @@ def landing(request, org, course, coursename):
# points to the temporary edge page
def edge(request):
return render_to_response('university_profiles/edge.html', {})
return redirect('/')
def event(request):
......
......@@ -90,10 +90,7 @@ def index(request, extra_context={}, user=None):
courses = get_courses(None, domain=domain)
courses = sort_by_announcement(courses)
# Get the 3 most recent news
top_news = _get_news(top=3)
context = {'courses': courses, 'news': top_news}
context = {'courses': courses}
context.update(extra_context)
return render_to_response('index.html', context)
......@@ -285,9 +282,6 @@ def dashboard(request):
exam_registrations = {course.id: exam_registration_info(request.user, course) for course in courses}
# Get the 3 most recent news
top_news = _get_news(top=3) if not settings.MITX_FEATURES.get('ENABLE_MKTG_SITE', False) else None
# get info w.r.t ExternalAuthMap
external_auth_map = None
try:
......@@ -302,7 +296,6 @@ def dashboard(request):
'errored_courses': errored_courses,
'show_courseware_links_for': show_courseware_links_for,
'cert_statuses': cert_statuses,
'news': top_news,
'exam_registrations': exam_registrations,
}
......@@ -1242,28 +1235,3 @@ def accept_name_change(request):
raise Http404
return accept_name_change_by_id(int(request.POST['id']))
def _get_news(top=None):
"Return the n top news items on settings.RSS_URL"
# Don't return anything if we're in a themed site
if settings.MITX_FEATURES["USE_CUSTOM_THEME"]:
return None
feed_data = cache.get("students_index_rss_feed_data")
if feed_data is None:
if hasattr(settings, 'RSS_URL'):
feed_data = urllib.urlopen(settings.RSS_URL).read()
else:
feed_data = render_to_string("feed.rss", None)
cache.set("students_index_rss_feed_data", feed_data, settings.RSS_TIMEOUT)
feed = feedparser.parse(feed_data)
entries = feed['entries'][0:top] # all entries if top is None
for entry in entries:
soup = BeautifulSoup(entry.description)
entry.image = soup.img['src'] if soup.img else None
entry.summary = soup.getText()
return entries
......@@ -24,13 +24,13 @@ def index(request):
from external_auth.views import ssl_login
return ssl_login(request)
if settings.MITX_FEATURES.get('ENABLE_MKTG_SITE'):
return redirect(settings.MKTG_URLS.get('ROOT'))
return redirect(settings.MKTG_URLS.get('ROOT'))
university = branding.get_university(request.META.get('HTTP_HOST'))
if university is None:
return student.views.index(request, user=request.user)
return courseware.views.university_profile(request, university)
return redirect('/')
@ensure_csrf_cookie
......@@ -48,4 +48,4 @@ def courses(request):
if university is None:
return courseware.views.courses(request)
return courseware.views.university_profile(request, university)
return redirect('/')
......@@ -632,57 +632,6 @@ def mktg_course_about(request, course_id):
'show_courseware_link': show_courseware_link})
@ensure_csrf_cookie
@cache_if_anonymous
def static_university_profile(request, org_id):
"""
Return the profile for the particular org_id that does not have any courses.
"""
# Redirect to the properly capitalized org_id
last_path = request.path.split('/')[-1]
if last_path != org_id:
return redirect('static_university_profile', org_id=org_id)
# Render template
template_file = "university_profile/{0}.html".format(org_id).lower()
context = dict(courses=[], org_id=org_id)
return render_to_response(template_file, context)
@ensure_csrf_cookie
@cache_if_anonymous
def university_profile(request, org_id):
"""
Return the profile for the particular org_id. 404 if it's not valid.
"""
virtual_orgs_ids = settings.VIRTUAL_UNIVERSITIES
meta_orgs = getattr(settings, 'META_UNIVERSITIES', {})
# Get all the ids associated with this organization
all_courses = modulestore().get_courses()
valid_orgs_ids = set(c.org for c in all_courses)
valid_orgs_ids.update(virtual_orgs_ids + meta_orgs.keys())
if org_id not in valid_orgs_ids:
raise Http404("University Profile not found for {0}".format(org_id))
# Grab all courses for this organization(s)
org_ids = set([org_id] + meta_orgs.get(org_id, []))
org_courses = []
domain = request.META.get('HTTP_HOST')
for key in org_ids:
cs = get_courses_by_university(request.user, domain=domain)[key]
org_courses.extend(cs)
org_courses = sort_by_announcement(org_courses)
context = dict(courses=org_courses, org_id=org_id)
template_file = "university_profile/{0}.html".format(org_id).lower()
return render_to_response(template_file, context)
def render_notifications(request, course, notifications):
context = {
'notifications': notifications,
......@@ -779,12 +728,16 @@ def submission_history(request, course_id, student_username, location):
except StudentModule.DoesNotExist:
return HttpResponse(escape("{0} has never accessed problem {1}".format(student_username, location)))
history_entries = StudentModuleHistory.objects.filter(student_module=student_module).order_by('-id')
history_entries = StudentModuleHistory.objects.filter(
student_module=student_module
).order_by('-id')
# If no history records exist, let's force a save to get history started.
if not history_entries:
student_module.save()
history_entries = StudentModuleHistory.objects.filter(student_module=student_module).order_by('-id')
history_entries = StudentModuleHistory.objects.filter(
student_module=student_module
).order_by('-id')
context = {
'history_entries': history_entries,
......
......@@ -29,7 +29,7 @@ from courseware.courses import course_image_url, get_course_about_section
% if stanford_theme_enabled():
<span class="university">${get_course_about_section(course, 'university')}</span>
% else:
<a href="${reverse('university_profile', args=[course.org])}" class="university">${get_course_about_section(course, 'university')}</a>
<a href="#" class="university">${get_course_about_section(course, 'university')}</a>
% endif
<span class="start-date">${course.start_date_text}</span>
</div>
......
<%! from django.utils.translation import ugettext as _ %>
<section class="filter">
<nav>
<div class="dropdown university">
<div class="filter-heading">
${_("All Universities")}
</div>
<ul>
<li>
<a href="#">Harvard</a>
</li>
<li>
<a href="#">MIT</a>
</li>
</ul>
</div>
<div class="dropdown subject">
<div class="filter-heading">
${_("All Subjects")}
</div>
<ul>
<li>
<a href="#">${_("Computer Science")}</a>
</li>
<li>
<a href="#">${_("History")}</a>
</li>
</ul>
</div>
<div class="dropdown featured">
<div class="filter-heading">
${_("Newest")}
</div>
<ul>
<li>
<a href="#">${_("Top Rated")}</a>
</li>
<li>
<a href="#">${_("Starting soonest")}</a>
</li>
</ul>
</div>
<form class="search">
<input type="text" placeholder="${_('Search for courses')}">
<input type="submit">
</form>
</nav>
</section>
......@@ -42,9 +42,9 @@
).css("display", "block");
}
});
%else:
$('#class_enroll_form').on('ajax:complete', function(event, xhr) {
if(xhr.status == 200) {
location.href = "${reverse('dashboard')}";
......@@ -52,14 +52,14 @@
location.href = "${reverse('register_user')}?course_id=${course.id}&enrollment_action=enroll";
} else {
$('#register_error').html(
(xhr.responseText ? xhr.responseText : ${_('An error occurred. Please try again later.')})
(xhr.responseText ? xhr.responseText : 'An error occurred. Please try again later.')
).css("display", "block");
}
});
%endif
})(this)
</script>
......@@ -77,7 +77,7 @@
<h1>
${course.number}: ${get_course_about_section(course, "title")}
% if not self.theme_enabled():
<a href="${reverse('university_profile', args=[course.org])}">${get_course_about_section(course, "university")}</a>
<a href="#">${get_course_about_section(course, "university")}</a>
% endif
</h1>
</hgroup>
......
......@@ -26,8 +26,6 @@
</header>
<section class="container">
## I'm removing this for now since we aren't using it for the fall.
## <%include file="course_filter.html" />
<section class="courses">
<ul class="courses-listing">
%for course in courses:
......
......@@ -16,46 +16,6 @@
<script type="text/javascript">
(function() {
var carouselPageHeight = 0;
var carouselIndex = 0;
var carouselDelay = 5000;
var carouselPages = $('.news-carousel .page').length;
$('.news-carousel .page').each(function() {
carouselPageHeight = Math.max($(this).outerHeight(), carouselPageHeight);
});
$('.news-carousel .pages').css('height', carouselPageHeight);
$('.news-carousel .page-dot').bind('click', setCarouselPage);
var carouselTimer = setInterval(nextCarouselPage, carouselDelay);
function nextCarouselPage() {
carouselIndex = carouselIndex + 1 < carouselPages ? carouselIndex + 1 : 0;
setCarouselPage(null, carouselIndex);
}
function setCarouselPage(event, index) {
var $pageToShow;
var transitionSpeed;
$('.news-carousel .page-dots').find('.current').removeClass('current');
if(event) {
clearInterval(carouselTimer);
carouselTimer = setInterval(nextCarouselPage, carouselDelay);
carouselIndex = $(this).closest('li').index();
transitionSpeed = 250;
$pageToShow = $('.news-carousel .page').eq(carouselIndex);
$(this).addClass('current');
} else {
transitionSpeed = 750;
$pageToShow = $('.news-carousel .page').eq(index);
$('.news-carousel .page-dot').eq(index).addClass('current');
}
$pageToShow.fadeIn(transitionSpeed);
$('.news-carousel .page').not($pageToShow).fadeOut(transitionSpeed);
}
$(".unenroll").click(function(event) {
$("#unenroll_course_id").val( $(event.target).data("course-id") );
$("#unenroll_course_number").text( $(event.target).data("course-number") );
......@@ -69,7 +29,7 @@
$("#unenroll_course_id").val() + "&enrollment_action=unenroll";
} else {
$('#unenroll_error').html(
xhr.responseText ? xhr.responseText : "${_('An error occurred. Please try again later.')}")
xhr.responseText ? xhr.responseText : "An error occurred. Please try again later."
).stop().css("display", "block");
}
});
......@@ -90,8 +50,15 @@
{"new_email" : new_email, "password" : new_password},
function(data) {
if (data.success) {
<<<<<<< HEAD
$("#change_email_title").html("${_('Please verify your new email')}"));
$("#change_email_form").html("<p>${_('You'll receive a confirmation in your in-box. Please click the link in the email to confirm the email change.')}</p>");
=======
$("#change_email_title").html("Please verify your new email");
$("#change_email_form").html("<p>You'll receive a confirmation in your " +
"in-box. Please click the link in the " +
"email to confirm the email change.</p>");
>>>>>>> a187bc7... fix registration
} else {
$("#change_email_error").html(data.error).stop().css("display", "block");
}
......@@ -108,7 +75,7 @@
function(data) {
if(data.success) {
location.reload();
// $("#change_name_body").html("<p>${_('Name changed.')}</p>");
// $("#change_name_body").html("<p>Name changed.</p>");
} else {
$("#change_name_error").html(data.error).stop().css("display", "block");
}
......@@ -158,40 +125,6 @@
</ul>
</section>
## `news` should be `None` whenever a non-edX theme is enabled:
## see common/djangoapps/student/views.py#_get_news
%if news:
<article class="news-carousel">
<header>
<h4>${_("edX News")}</h4>
<nav class="page-dots">
<ol>
<li><a href="#" class="page-dot current"></a></li>
<li><a href="#" class="page-dot"></a></li>
<li><a href="#" class="page-dot"></a></li>
</ol>
</nav>
</header>
<div class="pages">
% for entry in news:
<section class="page">
%if entry.image:
<div class="news-image">
<a href="${entry.link}"><img src="${entry.image}" /></a>
</div>
%endif
<h5><a href="${entry.link}">${entry.title}</a></h5>
<div class="excerpt">
%if entry.summary:
<p>${entry.summary}</p>
%endif
<p><a href="${entry.link}">${_("Learn More >")}</a></p>
</div>
</section>
%endfor
</div>
</article>
%endif
</section>
<section class="my-courses">
......
......@@ -61,7 +61,7 @@
<section class="university-partners university-partners2x6">
<ol class="partners">
<li class="partner mit">
<a href="${reverse('university_profile', args=['MITx'])}">
<a href="#">
<img src="${static.url('images/university/mit/mit.png')}" />
<div class="name">
<span>MITx</span>
......@@ -69,7 +69,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['HarvardX'])}">
<a href="#">
<img src="${static.url('images/university/harvard/harvard.png')}" />
<div class="name">
<span>HarvardX</span>
......@@ -77,7 +77,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['BerkeleyX'])}">
<a href="#">
<img src="${static.url('images/university/berkeley/berkeley.png')}" />
<div class="name">
<span>BerkeleyX</span>
......@@ -85,7 +85,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['UTx'])}">
<a href="#">
<img src="${static.url('images/university/ut/ut-rollover_350x150.png')}" />
<div class="name">
<span>UTx</span>
......@@ -93,7 +93,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['McGillX'])}">
<a href="#">
<img src="${static.url('images/university/mcgill/mcgill.png')}" />
<div class="name">
<span>McGillX</span>
......@@ -101,7 +101,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['ANUx'])}">
<a href="#">
<img src="${static.url('images/university/anu/anu.png')}" />
<div class="name">
<span>ANUx</span>
......@@ -114,7 +114,7 @@
<ol class="partners">
<li class="partner">
<a href="${reverse('university_profile', args=['WellesleyX'])}">
<a href="#">
<img src="${static.url('images/university/wellesley/wellesley-rollover_350x150.png')}" />
<div class="name">
<span>WellesleyX</span>
......@@ -122,7 +122,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['GeorgetownX'])}">
<a href="#">
<img src="${static.url('images/university/georgetown/georgetown-rollover_350x150.png')}" />
<div class="name">
<span>GeorgetownX</span>
......@@ -130,7 +130,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['TorontoX'])}">
<a href="#">
<img src="${static.url('images/university/toronto/toronto.png')}" />
<div class="name">
<span>University of TorontoX</span>
......@@ -138,7 +138,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['EPFLx'])}">
<a href="#">
<img src="${static.url('images/university/epfl/epfl.png')}" />
<div class="name">
<span>EPFLx</span>
......@@ -146,7 +146,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['DelftX'])}">
<a href="#">
<img src="${static.url('images/university/delft/delft.png')}" />
<div class="name">
<span>DelftX</span>
......@@ -154,7 +154,7 @@
</a>
</li>
<li class="partner">
<a href="${reverse('university_profile', args=['RiceX'])}">
<a href="#">
<img src="${static.url('images/university/rice/rice.png')}" />
<div class="name">
<span>RiceX</span>
......@@ -176,46 +176,6 @@
</section>
</section>
</section>
## Disable press and marketing for non-edX sites
% if not self.theme_enabled():
<section class="container">
<section class="more-info">
<header>
<h2>${_('{span_start}edX{span_end} News &amp; Announcements').format(span_start='<span class="edx">', span_end='</span>')}</h2>
<a class="action action-mediakit" href="${reverse('media-kit')}"> ${_('{span_start}edX{span_end} MEDIA KIT').format(span_start='<span class="org-name">', span_end='</span>')}</a>
</header>
<section class="news">
<section class="blog-posts">
%for entry in news:
<article>
%if entry.image:
<a href="${entry.link}" class="post-graphics" target="_blank"><img src="${entry.image}" /></a>
%endif
<div class="post-name">
<a href="${entry.link}" target="_blank">${entry.title}</a>
%if entry.summary:
<p>${entry.summary}</p>
%endif
<p class="post-date">${strftime("%m/%d/%y", entry.published_parsed)}</p>
</div>
</article>
%endfor
</section>
<section class="press-links">
<h3>${_("edX in the News:")}</h3>
<a target="_blank" href="http://www.nytimes.com/2013/04/30/education/adapting-to-blended-courses-and-finding-early-benefits.html?ref=education">${_("The New York Times")}</a>,
<a target="_blank" href="http://online.wsj.com/article/SB10001424127887323741004578414861572832182.html?mod=googlenews_wsj">${_("The Wall Street Journal")}</a>,
<a target="_blank" href="http://www.washingtonpost.com/local/education/stanford-to-help-build-edx-mooc-platform/2013/04/02/5b53bb3e-9bbe-11e2-9a79-eb5280c81c63_story.html">${_("The Washington Post")}</a>,
<a target="_blank" href="http://www.cbsnews.com/video/watch/?id=50143164n">${_("CBS Television")}</a>,
<a target="_blank" href="http://bostonglobe.com/2012/12/04/edx/AqnQ808q4IEcaUa8KuZuBO/story.html">${_("The Boston Globe")}</a>
<a href="${reverse('press')}" class="read-more">${_("Read More")} &rarr;</a>
</section>
</section>
</section>
</section>
% endif
</section>
<section id="video-modal" class="modal home-page-video-modal video-modal">
......
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("ANUx")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/anu/anu-cover.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/anu/anu.png')}" />
</div>
<h1>${_("ANUx")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("The Australian National University (ANU) is a celebrated place of intensive research, education and policy engagement. Our research has always been central to everything we do, shaping a holistic learning experience that goes beyond the classroom, giving students access to researchers who are among the best in their fields and to opportunities for development around Australia and the world.")}</p>
</%block>
${parent.body()}
<%inherit file="../main.html" />
<%namespace name='static' file='../static_content.html'/>
<section class="find-courses">
<%block name="university_header"/>
<section class="container">
<section class="courses university-courses">
%for course in courses:
<%include file="../course.html" args="course=course" />
%endfor
</section>
<section class="message left">
<%block name="university_description" />
</section>
</section>
<%block name="js_extra">
<script type="text/javascript" src="${static.url('js/query-params.js')}"></script>
<script type="text/javascript"">
$(window).load(function() {
if(getParameterByName('next')) {
$('#login').trigger("click");
}
})
</script>
</%block>
</section>
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("BerkeleyX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/berkeley/berkeley_fountain_2025x550.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/berkeley/berkeley.png')}" />
</div>
<h1>${_("BerkeleyX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("The University of California, Berkeley was chartered in 1868 and its flagship campus - envisioned as a \"City of Learning\" - was established at Berkeley, on San Francisco Bay. Berkeley Faculty consists of 1,582 fulltime and 500 part-time faculty members dispersed among more than 130 academic departments and more than 80 interdisciplinary research units. 28 Nobel prizes have been awarded to Berkeley Alumni. There are eight Nobel Laureates, 32 MacArthur Fellows, and four Pulitzer Prize winners among the current faculty.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("DelftX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/delft/delft-cover.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/delft/delft.png')}" />
</div>
<h1>${_("DelftX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("Delft University of Technology is the largest and oldest technological university in the Netherlands. Our research is inspired by the desire to increase fundamental understanding, as well as by societal challenges. We encourage our students to be independent thinkers so they will become engineers capable of solving complex problems. Our students have chosen Delft University of Technology because of our reputation for quality education and research.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="../stripped-main.html" />
<%! from django.core.urlresolvers import reverse %>
<%block name="title"><title>${_("edX edge")}</title></%block>
<%block name="bodyclass">no-header edge-landing</%block>
<%block name="content">
<div class="main-wrapper">
<div class="edx-edge-logo-large">${_("edX edge")}</div>
<div class="content">
<div class="log-in-form">
<h2>${_("Log in to your courses")}</h2>
<form id="login_form" data-remote="true" method="post" action="/login_ajax">
<div class="row">
<label>${_("Email")}</label>
<input name="email" type="email" class="email-field" tabindex="1">
</div>
<div class="row">
<label>${_("Password")}</label>
<input name="password" type="password" class="password-field" tabindex="2">
</div>
<div class="row submit">
<input name="submit" type="submit" value="${_("Log In")}" class="log-in-submit-button" tabindex="3">
<a href="#forgot-password-modal" rel="leanModal" class="pwd-reset forgot-button">${_("Forgot password?")}</a>
</div>
</form>
</div>
<div class="sign-up">
<h3>${_("Register for classes")}</h3>
<p>${_("Take free online courses from today's leading universities.")}</p>
<p><a href="#signup-modal" id="signup" rel="leanModal" class="register-button">${_("Register")}</a></p>
</div>
</div>
</div>
</%block>
<%block name="js_extra">
<script type="text/javascript">
(function() {
$(document).ready(function() {
if ($.deparam.fragment()['forgot-password-modal'] !== undefined) {
$('.pwd-reset').click();
}
})
$(document).delegate('#login_form', 'ajax:success', function(data, json, xhr) {
if(json.success) {
next = getParameterByName('next');
if(next) {
location.href = next;
} else {
location.href = "${reverse('dashboard')}";
}
} else {
if($('#login_error').length == 0) {
$('#login_form').prepend('<div id="login_error" class="modal-form-error"></div>');
}
$('#login_error').html(json.value).stop().css("display", "block");
}
});
})(this)
</script>
</%block>
<%include file="../signup_modal.html" />
<%include file="../forgot_password_modal.html" />
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("EPFLx")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/epfl/epfl-cover.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/epfl/epfl.png')}" />
</div>
<h1>${_("EPFLx")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("EPFL is the Swiss Federal Institute of Technology in Lausanne. The past decade has seen EPFL ascend to the very top of European institutions of science and technology: it is ranked #1 in Europe in the field of engineering by the Times Higher Education (based on publications and citations), Leiden Rankings, and the Academic Ranking of World Universities.")}</p>
<p>${_("EPFL's main campus brings together 12,600 students, faculty, researchers, and staff in a high-energy, dynamic learning and research environment. It directs the Human Brain Project, an undertaking to simulate the entire human brain using supercomputers, in order to gain new insights into how it operates and to better diagnose brain disorders. The university is building Solar Impulse, a long-range solar-powered plane that aims to be the first piloted fixed-wing aircraft to circumnavigate the Earth using only solar power. EPFL was part of the Alinghi project, developing advanced racing boats that won the America's Cup multiple times. The university operates, for education and research purposes, a Tokamak nuclear fusion reactor. EPFL also houses the Musee Bolo museum and hosts several music festivals, including Balelec, that draws over 15,000 guests every year.")}</p>
<p>${_("EPFL is a major force in entrepreneurship, with 2012 bringing in $100M in funding for ten EPFL startups. Both young spin-offs (like Typesafe and Pix4D) and companies that have long grown past the startup stage (like Logitech) actively transfer the results of EPFL's scientific innovation to industry.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("GeorgetownX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/georgetown/georgetown-cover_2025x550.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/georgetown/georgetown.png')}" />
</div>
<h1>${_("GeorgetownX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("Georgetown University, the nation's oldest Catholic and Jesuit university, is one of the world's leading academic and research institutions, offering a unique educational experience that prepares the next generation of global citizens to lead and make a difference in the world. Students receive a world-class learning experience focused on educating the whole person through exposure to different faiths, cultures and beliefs.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("HarvardX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/harvard/about_harvard_page_2025x550.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/harvard/harvard.png')}" />
</div>
<h1>${_("HarvardX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("Harvard University is devoted to excellence in teaching, learning, and research, and to developing leaders in many disciplines who make a difference globally. Harvard faculty are engaged with teaching and research to push the boundaries of human knowledge. The University has twelve degree-granting Schools in addition to the Radcliffe Institute for Advanced Study.")}</p>
<p>${_("Established in 1636, Harvard is the oldest institution of higher education in the United States. The University, which is based in Cambridge and Boston, Massachusetts, has an enrollment of over 20,000 degree candidates, including undergraduate, graduate, and professional students. Harvard has more than 360,000 alumni around the world.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("McGillX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/mcgill/mcgill-cover.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/mcgill/mcgill.png')}" />
</div>
<h1>${_("McGillX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("McGill University is one of Canada's best-known institutions of higher learning and one of the leading universities in the world. McGill is located in vibrant multicultural Montreal, in the province of Quebec. Our 11 faculties and 11 professional schools offer more than 300 programs to some 38,000 graduate, undergraduate and continuing studies students. McGill ranks 1st in Canada among medical-doctoral universities (Maclean\'s) and 18th in the world (QS World University Rankings).")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("MITx")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/mit/shot-2-large.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/mit/mit.png')}" />
</div>
<h1>${_("MITx")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("The Massachusetts Institute of Technology &mdash; a coeducational, privately endowed research university founded in 1861 &mdash; is dedicated to advancing knowledge and educating students in science, technology, and other areas of scholarship that will best serve the nation and the world in the 21st century. The Institute has close to 1,000 faculty and 10,000 undergraduate and graduate students. It is organized into five Schools: Architecture and Urban Planning; Engineering; Humanities, Arts, and Social Sciences; Sloan School of Management; and Science.")}</p>
<p>${_("MIT's commitment to innovation has led to a host of scientific breakthroughs and technological advances. Achievements of the Institute's faculty and graduates have included the first chemical synthesis of penicillin and vitamin A, the development of inertial guidance systems, modern technologies for artificial limbs, and the magnetic core memory that made possible the development of digital computers. 78 alumni, faculty, researchers and staff have won Nobel Prizes.")}</p>
<p>${_("Current areas of research and education include neuroscience and the study of the brain and mind, bioengineering, cancer, energy, the environment and sustainable development, information sciences and technology, new media, financial technology, and entrepreneurship.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("RiceX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/rice/rice-cover.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/rice/rice.png')}" />
</div>
<h1>${_("RiceX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("Located on a 300-acre forested campus in Houston, Rice University is consistently ranked among the nation's top 20 universities by U.S. News & World Report. Rice has highly respected schools of Architecture, Business, Continuing Studies, Engineering, Humanities, Music, Natural Sciences and Social Sciences and is home to the Baker Institute for Public Policy. With 3,708 undergraduates and 2,374 graduate students, Rice's undergraduate student-to-faculty ratio is 6-to-1. Its residential college system builds close-knit communities and lifelong friendships, just one reason why Rice has been ranked No. 1 for best quality of life multiple times by the Princeton Review and No. 2 for \"best value\" among private universities by Kiplinger's Personal Finance.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("SCHOOLX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/SCHOOL/IMAGE.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/SCHOOL/IMAGE.png')}" />
</div>
<h1>${_("SCHOOLX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p></p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("University of TorontoX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/toronto/toronto-cover.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/toronto/toronto.png')}" />
</div>
<h1>${_("University of TorontoX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("Established in 1827, the University of Toronto is a vibrant and diverse academic community. It includes 80,000 students, 12,000 colleagues holding faculty appointments, 200 librarians, and 6,000 staff members across three distinctive campuses and at many partner sites, including world-renowned hospitals. With over 800 undergraduate programs, 150 graduate programs, and 40 professional programs, U of T attracts students of the highest calibre, from across Canada and from 160 countries around the world. The University is one of the most respected and influential institutions of higher education and advanced research in the world. Its strengths extend across the full range of disciplines: the 2012-13 Times Higher Education ranking groups the University of Toronto with Stanford, UC Berkeley, UCLA, Columbia, Cambridge, Oxford, the University of Melbourne, and the University of Michigan as the only institutions in the top 27 in all 6 broad disciplinary areas. The University is also consistently rated one of Canada\'s Top 100 employers, and ranks with Harvard and Yale for the top university library resources in North America.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("UTAustinX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/utaustin/utaustin-cover_2025x550.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/utaustin/utaustin-standalone_187x80.png')}" />
</div>
<h1>${_("UTAustinx")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("The University of Texas at Austin is the top-ranked public university in a nearly 1,000-mile radius, and is ranked in the top 25 universities in the world. Students have been finding their passion in life at UT Austin for more than 130 years, and it has been a member of the prestigious AAU since 1929. UT Austin combines the academic depth and breadth of a world research institute (regularly ranking within the top three producers of doctoral degrees in the country) with the fun and excitement of a big-time collegiate experience. It is currently the fifth-largest university in America, with more than 50,000 students and 3,000 professors across 17 colleges and schools. UT Austin will be opening the Dell Medical School in 2016.")}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%!
from django.core.urlresolvers import reverse
%>
<%block name="title"><title>${_("UTx")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/ut/ut-cover_2025x550.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/ut/ut-standalone_187x80.png')}" />
</div>
<h1>${_("UTx")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("Educating students, providing care for patients, conducting groundbreaking research and serving the needs of Texans and the nation for more than 130 years, The University of Texas System is one of the largest public university systems in the United States, with nine academic universities and six health science centers. Student enrollment exceeded 215,000 in the 2011 academic year. The UT System confers more than one-third of the state\'s undergraduate degrees and educates nearly three-fourths of the state\'s health care professionals annually. The UT System has an annual operating budget of $13.1 billion (FY 2012) including $2.3 billion in sponsored programs funded by federal, state, local and private sources. With roughly 87,000 employees, the UT System is one of the largest employers in the state.")}</p>
<p>${_('Find out about <a href="%s">The University of Texas at Austin</a>.') % reverse('university_profile', args=['UTAustinX'])}</p>
</%block>
${parent.body()}
<%! from django.utils.translation import ugettext as _ %>
<%inherit file="base.html" />
<%namespace name='static' file='../static_content.html'/>
<%block name="title"><title>${_("WellesleyX")}</title></%block>
<%block name="university_header">
<header class="search" style="background: url('/static/images/university/wellesley/wellesley-cover_2025x550.jpg')">
<div class="inner-wrapper university-search">
<hgroup>
<div class="logo">
<img src="${static.url('images/university/wellesley/wellesley.png')}" />
</div>
<h1>${_("WellesleyX")}</h1>
</hgroup>
</div>
</header>
</%block>
<%block name="university_description">
<p>${_("Since 1875, Wellesley College has been the preeminent liberal arts college for women. Known for its intellectual rigor and its remarkable track record for the cultivation of women leaders in every arena, Wellesley-only 12 miles from Boston-is home to some 2300 undergraduates from every state and 75 countries.")}</p>
</%block>
${parent.body()}
......@@ -73,32 +73,6 @@ urlpatterns += (
url(r'^jsi18n/$', 'django.views.i18n.javascript_catalog', js_info_dict),
)
# University profiles only make sense in the default edX context
if not settings.MITX_FEATURES["USE_CUSTOM_THEME"]:
urlpatterns += (
##
## Only universities without courses should be included here. If
## courses exist, the dynamic profile rule below should win.
##
url(r'^(?i)university_profile/WellesleyX$', 'courseware.views.static_university_profile',
name="static_university_profile", kwargs={'org_id': 'WellesleyX'}),
url(r'^(?i)university_profile/McGillX$', 'courseware.views.static_university_profile',
name="static_university_profile", kwargs={'org_id': 'McGillX'}),
url(r'^(?i)university_profile/TorontoX$', 'courseware.views.static_university_profile',
name="static_university_profile", kwargs={'org_id': 'TorontoX'}),
url(r'^(?i)university_profile/RiceX$', 'courseware.views.static_university_profile',
name="static_university_profile", kwargs={'org_id': 'RiceX'}),
url(r'^(?i)university_profile/ANUx$', 'courseware.views.static_university_profile',
name="static_university_profile", kwargs={'org_id': 'ANUx'}),
url(r'^(?i)university_profile/EPFLx$', 'courseware.views.static_university_profile',
name="static_university_profile", kwargs={'org_id': 'EPFLx'}),
url(r'^university_profile/(?P<org_id>[^/]+)$', 'courseware.views.university_profile',
name="university_profile"),
)
#Semi-static views (these need to be rendered and have the login bar, but don't change)
urlpatterns += (
url(r'^404$', 'static_template_view.views.render',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment