Team:TU Delft/pages/blog

From 2010.igem.org

(Difference between revisions)
 
(40 intermediate revisions not shown)
Line 1: Line 1:
 +
==Blog==
 +
Follow our progress day by day via our blog. Also don't forget to become a fan of our [http://tiny.cc/igemtudelft Facebook page] or [http://twitter.com/igemtudelft2010 follow us on Twitter].
 +
 +
==Calendar==
<html>
<html>
-
<div id="article_wrap">
+
<div id="calendar_container" style="width: 300px; float: right;"></html>
-
<h2>Blog</h2>
+
{{:Team:TU_Delft/scroll_calendar}}
-
<p>Follow our progress day by day via our blog. Also don't forget to become a fan of our <a href="http://tiny.cc/igemtudelft">Facebook page</a> or <a href="http://twitter.com/igemtudelft2010">follow us on Twitter</a>.</p>
+
<html></div>
 +
 
 +
<div style="width: 450px;">
 +
<h2><span class="mv-headline" id="blog_item_date">Today's post</span></h2>
 +
<div id="blog_item_container"></div>
 +
<div style="display:none;" id="blog_item_next"></div>
 +
<div style="clear:both;"></div>
</div>
</div>
-
 
+
<div id="fb-root"></div>
-
<div id="article_wrap">
+
<div id="blog_item_fbcomments"></div>
-
<h2>Todays Post</h2>
+
-
<table style="width: 600px; display: block; overflow: hidden;"><tr><td>
+
</html>
</html>
-
{{:Team:TU_Delft/{{CURRENTDAY}}_{{CURRENTMONTHNAME}}_{{CURRENTYEAR}}_content}}
 
-
<html>
 
-
</td></tr></table>
 
-
</div>
 
-
<h2>Calendar</h2>
 
-
<table id="calendar">
 
-
<tr>
 
-
<td valign=top>
 
-
</html>
 
-
{| style="background:transparent;"
 
-
|{{#calendar: query=preload=Team:TU_Delft/NotebookPreload | year=2010 | month=06 | title=Team:TU_Delft}}
 
-
|}
 
<html>
<html>
-
</td>
+
<!-- <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.js"></script> -->
-
<td width="10">
+
<script type="text/javascript">
-
</td>
+
-
<td valign=top>
+
var datePickerLoaded = false;
-
</html>
+
-
{| style="background:transparent;"
+
-
|{{#calendar: query=preload=Team:TU_Delft/NotebookPreload | year=2010 | month=07 | title=Team:TU_Delft}}
+
-
|}
+
-
<html>
+
-
</td>
+
-
<td width="10">
+
function dbgout(msg) {
-
</td>
+
  var is_chrome = navigator.userAgent.toLowerCase().indexOf('chrome') > -1;
 +
  if(is_chrome) console.log(msg);
 +
}
-
<td valign=top>
+
function blog_loadDate(date) {
-
</html>
+
  var datestr = jQuery.datepicker.formatDate("d_MM_yy", date);
-
{| style="background:transparent;"
+
  var url = "/Team:TU_Delft/"+datestr+"_content?action=render";
-
|{{#calendar: query=preload=Team:TU_Delft/NotebookPreload | year=2010 | month=08 | title=Team:TU_Delft}}
+
  setActiveMonth(date.getMonth() - 2);
-
|}
+
  dbgout('blog_loadDate: ' + date);
-
<html>
+
-
</td>
+
-
</tr>
+
  $.get(url, function(response) {
-
<tr>
+
    $("#blog_item_container").fadeOut(200).queue(function(next) {
 +
      $(this).html(response);
 +
      var refURL = "http://2010.igem.org/Team:TU_Delft#/blog?blog=" + datestr;
 +
      $("#blog_item_date").text(jQuery.datepicker.formatDate("d MM yy", date));
 +
      $("#blog_item_fbcomments").html('<fb:comments url="' + refURL + '" xid="igemblog' + datestr +'" numposts="10" width="450"></fb:comments>');
 +
      FB.XFBML.parse(document.getElementById('blog_item_fbcomments'));
 +
      next();
 +
    }).fadeIn(200);
 +
  });
 +
}
-
<td valign=top>
 
-
</html>
 
-
{| style="background:transparent;"
 
-
|{{#calendar: query=preload=Team:TU_Delft/NotebookPreload | year=2010 | month=09 | title=Team:TU_Delft}}
 
-
|}
 
-
<html>
 
-
</td>
 
-
<td width="10">
+
function blog_hashchange_cb() {
-
</td>
+
  dbgout('blog_hashchange');
-
<td>
+
  hash = location.hash.substring(1);
-
</html>
+
  var kvmap = splitHash(hash);
-
{| style="background:transparent;"
+
-
|{{#calendar: query=preload=Team:TU_Delft/NotebookPreload | year=2010 | month=10 | title=Team:TU_Delft}}
+
-
|}
+
-
<html>
+
-
</td>
+
-
<td width="10">
+
  if (kvmap.blog)
-
</td>
+
    blog_loadDate($.datepicker.parseDate('d_MM_yy', kvmap.blog));
 +
}
-
<td>
+
function blogInit() {
-
</html>
+
  dbgout('blogInit');
-
{| style="background:transparent;"
+
 
-
|{{#calendar: query=preload=Team:TU_Delft/NotebookPreload | year=2010 | month=11 | title=Team:TU_Delft}}
+
  initScrollCalendar();
-
|}
+
 
-
<html>
+
  setCalendarLinks (function(day, mo, hasEntry) {
-
</td>
+
  // console.log('Day: ' + day + '; Mo: ' + mo + '; hasentry=' + hasEntry);
-
</tr>
+
    return makeHash('pages/blog', { blog: day + '_' + mo + '_2010'});
-
</table>
+
  });
 +
  setHash('pages/blog', { blog: $.datepicker.formatDate("d_MM_yy", new Date()) } );
 +
 
 +
  dbgout('bind hashupdate');
 +
  $(window).bind('hashupdate', blog_hashchange_cb);
 +
}
 +
 
 +
$(function() {
 +
  loadScript('http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.js', function() {
 +
 
 +
  if (jQuery.support.boxModel) {
 +
// facebook initialization code
 +
  window.fbAsyncInit = function() {
 +
    FB.init({appId: '132572820109093', status: true, cookie: true, xfbml: true});
 +
    blogInit();
 +
  };
 +
 
 +
  var e = document.createElement('script'); e.async = true;
 +
  e.src = document.location.protocol + '//connect.facebook.net/en_US/all.js';
 +
  document.getElementById('fb-root').appendChild(e);
 +
  } else {
 +
    $("#blog_item_fbcomments").text("Facebook comments unsupported on this browser.");
 +
    blogInit();
 +
  }
 +
  });
 +
});
 +
 
 +
var blogpage_close = function() {
 +
  dbgout('unbind hashupdate');
 +
  $(window).unbind('hashupdate', blog_hashchange_cb);
 +
};
 +
 
 +
$(window).bind('page_close', blogpage_close);
 +
</script>
</html>
</html>

Latest revision as of 14:25, 16 September 2010

Blog

Follow our progress day by day via our blog. Also don't forget to become a fan of our Facebook page or follow us on Twitter.

Calendar

March
MTWTFSS
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31
April
MTWTFSS
    1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30
May
MTWTFSS
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31
June
MTWTFSS
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30
July
MTWTFSS
    1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31
August
MTWTFSS
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31
September
MTWTFSS
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30
October
MTWTFSS
      1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
November
MTWTFSS
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30

Today's post