Added an archive embed for the IRI homepage V01.30
authorRaphael Velt <raph.velt@gmail.com>
Fri, 10 Feb 2012 16:31:09 +0100
changeset 495 34f92d5b2acf
parent 494 36b25df474ac
child 496 e307f08f59c5
Added an archive embed for the IRI homepage
web/archives-iframe.php
web/common.php
web/res/css/archives-iframe.css
web/traduction.php
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/web/archives-iframe.php	Fri Feb 10 16:31:09 2012 +0100
@@ -0,0 +1,101 @@
+<?php
+error_reporting(E_ALL);
+ini_set('display_errors', '1');
+/**
+ * include some common code (like we did in the 90s)
+ * People still do this? ;)
+ */
+include_once './common.php';
+
+function special_display_archives_list($archives_list, $box_class, $url_root, $basepath, &$translate) {
+    
+    
+    for($i=0;$i<count($archives_list);$i++) {
+        print("             <div class=\"$box_class\">\n");
+        $archive_ref = $archives_list[$i];
+    
+        $archive_name = $archive_ref;
+        $metadata = null;
+        if(is_array($archive_ref)) {
+            $archive_name = $archive_ref[0];
+            $metadata = $archive_ref[1];
+        }
+        print(get_archive_box($archive_name,$metadata, $url_root, $basepath, $translate));
+        print("             </div>\n");
+    }
+}
+
+?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<html lang="<?php echo($actual); ?>">
+  <head>
+    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+    <title>Polemic tweet - Live Video and Annotation</title>
+
+    <link rel="stylesheet" href="<?php echo(registry_url('archives-iframe','css'));?>" type="text/css" media="screen, projection"/>
+
+    <!-- JAVASCRIPT -->
+    <script type="text/javascript" src="<?php echo(registry_url('jquery','js'));?>"></script>
+    <script type="text/javascript" src="<?php echo(registry_url('jquery-tools','js'));?>"></script>
+
+    <!-- FONT -->
+    <link href='<?php echo(registry_url('PT-Sans_Narrow','font'));?>' rel='stylesheet' type='text/css'>
+
+    <script type="text/javascript">
+        var _timerJqScroll;
+        function startTimer() {
+            if (_timerJqScroll) {
+                clearInterval(_timerJqScroll);
+            }
+            _timerJqScroll = setInterval(function() { $(".scrollable").scrollable().next()}, 5000);
+        }
+        $(function() {
+            $(".archivesVideoBox").mouseover(function() {
+                $(this).css({'backgroundColor':'#fff'});
+                $(this).cursor = "pointer";
+            }).mouseout(function() {
+                $(this).css({'backgroundColor':'#f2f2f2'});
+            });
+            $(".scrollable").scrollable({"circular":true});
+            $(".browse, .item").click(function() {
+                startTimer();
+            })
+            startTimer();
+        });
+
+        var _gaq = _gaq || [];
+        _gaq.push(['_setAccount', 'UA-23581291-1']);
+        _gaq.push(['_trackPageview']);
+        _gaq.push(['_setAllowAnchor', true]);
+      
+        (function() {
+            var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
+            ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
+            var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
+        })();
+    
+    </script>
+  </head>
+  <body>
+        <div class="archivesTitleContainer">
+            <h3 class="archivesTitle"><?php print $translate->_("shortArchive"); ?></h3>
+        </div>
+        <div class="archivesBoxContainer scrollable">
+            <!-- -->
+            <div class="archivesTitleActionsContainer">
+                <div class="archivesActionsContainer" id="actions">
+                    <a class="prev browse left"></a>
+                    <a class="next browse right"></a>
+                </div>
+            </div>
+            
+            <!-- -->
+            <div class="items">
+                <?php
+                $arch_list = array_reverse($archives_list);
+                special_display_archives_list($arch_list, "archive_box_3 item", URL_ROOT, dirname(__FILE__)."/", $translate);
+                ?>
+            </div>
+        </div>
+  </body>
+</html>
\ No newline at end of file
--- a/web/common.php	Mon Feb 06 10:54:07 2012 +0100
+++ b/web/common.php	Fri Feb 10 16:31:09 2012 +0100
@@ -238,6 +238,7 @@
 		'tabs-slideshow' => URL_ROOT.'res/css/tabs-slideshow.css',
 		'tweetcast' => URL_ROOT.'res/css/tweetcast.css',
 		'semanticboard' =>  URL_ROOT.'res/css/semanticboard.css',
+        'archives-iframe' => URL_ROOT.'res/css/archives-iframe.css',
 	),
 	'cdn' => array(
 		'blueprint-screen' => URL_ROOT.'res/blueprint/screen.css',
@@ -250,6 +251,7 @@
 		'tabs-slideshow' => URL_ROOT.'res/css/tabs-slideshow.css',
         'tweetcast' => URL_ROOT.'res/css/tweetcast.css',
         'semanticboard' =>  URL_ROOT.'res/css/semanticboard.css',
+        'archives-iframe' => URL_ROOT.'res/css/archives-iframe.css',
 	)
 );
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/web/res/css/archives-iframe.css	Fri Feb 10 16:31:09 2012 +0100
@@ -0,0 +1,108 @@
+body {
+    background: #ffffff;
+    padding: 0;
+    margin: 0;
+    font-family: "PT Sans Narrow";
+}
+div, p, img {
+    margin: 0;
+    padding: 0;
+    border: none;
+}
+a img {
+    border: none;
+    display: block;
+    max-width: 266px;
+    text-align: center;
+}
+.archivesTitleContainer {
+    width: 270px;
+    padding: 0;
+    margin: 0;
+}
+.archivesTitle {
+    color: #4b4b4b;
+    font-size: 18px;
+    margin: 0;
+    text-align: center;
+}
+.archivesBoxContainer {
+    width: 270px;
+    padding: 0;
+    margin: 0;
+    height: 235px;
+}
+.archivesActionsContainer {
+    float: right;
+}
+.archivesTitleActionsContainer {
+    float: left;
+    width: 100%;
+}
+.archivesVideoBox {
+    position: relative;
+    display: inline-block;
+    float: left;
+    background: #f2f2f2;
+    cursor: pointer;
+    width: 266px;
+    padding: 2px;
+    overflow: hidden;
+}
+.AVBtitle {
+    font-weight: bold;
+    font-size: 16.5px;
+    white-space: nowrap;
+    overflow: hidden;
+}
+.AVBtext {
+    font-size: 12px;
+    white-space: nowrap;
+    overflow: hidden;
+}
+.scrollable {
+    position: relative;
+    overflow: hidden;
+    /*    width: 660px;*/
+}
+.scrollable .items {
+    /* this cannot be too large */
+    position: absolute;
+    top: 22px;
+    width: 20000em;
+}
+.item {
+    float: left;
+}
+a.browse {
+    background: url(../../images/horizontal.png) no-repeat;
+    display: block;
+    float: left;
+    width: 20px;
+    height: 20px;
+    cursor: pointer;
+    font-size: 1px;
+}
+a.right {
+    background-position: 0 -20px;
+    margin-left: 5px;
+}
+a.right:hover {
+    background-position: -20px -20px;
+}
+a.right:active {
+    background-position: -40px -20px;
+}
+/* left */
+a.left {
+    margin-left: 0px;
+}
+a.left:hover {
+    background-position: -20px 0;
+}
+a.left:active {
+    background-position: -40px 0;
+}
+#actions a.disabled {
+    visibility: hidden !important;
+}
\ No newline at end of file
--- a/web/traduction.php	Mon Feb 06 10:54:07 2012 +0100
+++ b/web/traduction.php	Fri Feb 10 16:31:09 2012 +0100
@@ -63,6 +63,7 @@
 										"Comment les algorithmes ont fini par devenir des producteurs d&apos;infos et pourquoi ils ne remplaceront pour autant jamais les journalistes."',
 				'4. Button'			=> 'Cliquez ici pour aller sur la page de live',
 				"Archive Title :" 		=> 'Les derniers événements qui ont utilisé Polemic Tweet :',
+				"shortArchive" => 'Derniers événements Polemic Tweet',
 				"footer text home" 	=> "<a href='http://www.iri.centrepompidou.fr/' class='footerLink' target='_blank'> Polemic Tweet </a>
 										est une expérimentation de l&apos;<a href='http://www.iri.centrepompidou.fr/' class='footerLink' target='_blank'>
 										Institut de Recherche et d’Innovation </a>",
@@ -194,6 +195,7 @@
                 '4. Button'			=> 'Click here to access the live page',
                 '4. TextSlide'  	=> 'RSLN invites you on April 7 at 7.30 PM for a meeting with Mercedes Bunz on the topic “How algorythms became info producers and why they wont replace journalist',
 				"Archive Title :" 	=> 'Last events using Polemic Tweet :',
+                "shortArchive" => 'Last Polemic Tweet events',
 				"footer text home" 	=> "<a href='http://www.iri.centrepompidou.fr/' class='footerLink'> Tweet polemic </a>
 										is an expériment of the <a href='http://www.iri.centrepompidou.fr/' class='footerLink'>
 										Institut for Research and Innovation </a>",
@@ -342,6 +344,7 @@
                 '4. TextSlide'  	=> 'RSLN invites you on April 7 at 7.30 PM for a meeting with Mercedes Bunz on the topic “How algorythms became info producers and why they wont replace journalist',
                 '4. Button'			=> 'ライブ中継ページへは、このボタンをクリック',
 				"Archive Title :" 	=> 'これまでのイベント',
+                "shortArchive" => 'これまでのイベント',
 				"footer text home" 	=> "<a href='http://www.iri.centrepompidou.fr/' class='footerLink'> Tweet polemic </a>
 										is an expériment of the <a href='http://www.iri.centrepompidou.fr/' class='footerLink'>
 										Institut for Research and Innovation </a>",