Commit dc8bd32f by Nate Hardison

Theme the individual course about pages

Use the theme's own Google Analytics template (should probably
update to just use parameters once the default GA template is kept
up-to-date). Don't link to the university profile page when a theme
is enabled, as that's an edX-specific feature. Adjust social links
for Stanford, but leave them alone for everyone else (this is just
a hack for the 6/11/13 launch).
parent 227271fe
...@@ -8,7 +8,11 @@ ...@@ -8,7 +8,11 @@
<%inherit file="../main.html" /> <%inherit file="../main.html" />
<%block name="headextra"> <%block name="headextra">
<%include file="../google_analytics.html" /> % if self.theme_enabled():
<%include file="../theme-google-analytics.html" />
% else:
<%include file="../google_analytics.html" />
% endif
</%block> </%block>
<%block name="js_extra"> <%block name="js_extra">
...@@ -46,7 +50,12 @@ ...@@ -46,7 +50,12 @@
<div class="table"> <div class="table">
<section class="intro"> <section class="intro">
<hgroup> <hgroup>
<h1>${course.number}: ${get_course_about_section(course, "title")}<a href="${reverse('university_profile', args=[course.org])}">${get_course_about_section(course, "university")}</a></h1> <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>
% endif
</h1>
</hgroup> </hgroup>
<div class="main-cta"> <div class="main-cta">
...@@ -105,14 +114,26 @@ ...@@ -105,14 +114,26 @@
<header> <header>
<div class="social-sharing"> <div class="social-sharing">
<div class="sharing-message">Share with friends and family!</div> <div class="sharing-message">Share with friends and family!</div>
<a href="http://twitter.com/intent/tweet?text=I+just+registered+for+${course.number}+${get_course_about_section(course, 'title')}+through+@edxonline:+http://www.edx.org${reverse('about_course', args=[course.id])}" class="share"> ## TODO: this should probably be an overrideable block,
<img src="${static.url('images/social/twitter-sharing.png')}"> ## or something allowing themes to do whatever they
</a> ## want here (and on this whole page, really).
<a href="http://www.facebook.com/EdxOnline" class="share"> <img src="${static.url('images/social/facebook-sharing.png')}"> % if self.stanford_theme_enabled():
</a> <a href="http://twitter.com/intent/tweet?text=I+just+registered+for+${course.number}+${get_course_about_section(course, 'title')}!+(http://class.stanford.edu)" class="share">
<a href="mailto:?subject=Take%20a%20course%20with%20edX%20online&body=I%20just%20registered%20for%20${course.number}%20${get_course_about_section(course, 'title')}%20through%20edX:+http://edx.org/${reverse('about_course', args=[course.id])}" class="share"> <img src="${static.url('images/social/twitter-sharing.png')}">
<img src="${static.url('images/social/email-sharing.png')}"> </a>
</a> <a href="mailto:?subject=Take%20a%20course%20at%20Stanford%20online!&body=I%20just%20registered%20for%20${course.number}%20${get_course_about_section(course, 'title')}+(http://class.stanford.edu)" class="share">
<img src="${static.url('images/social/email-sharing.png')}">
</a>
% else:
<a href="http://twitter.com/intent/tweet?text=I+just+registered+for+${course.number}+${get_course_about_section(course, 'title')}+through+@edxonline:+http://www.edx.org${reverse('about_course', args=[course.id])}" class="share">
<img src="${static.url('images/social/twitter-sharing.png')}">
</a>
<a href="http://www.facebook.com/EdxOnline" class="share"> <img src="${static.url('images/social/facebook-sharing.png')}">
</a>
<a href="mailto:?subject=Take%20a%20course%20with%20edX%20online&body=I%20just%20registered%20for%20${course.number}%20${get_course_about_section(course, 'title')}%20through%20edX:+http://edx.org/${reverse('about_course', args=[course.id])}" class="share">
<img src="${static.url('images/social/email-sharing.png')}">
</a>
% endif
</div> </div>
</header> </header>
......
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