Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
553 lines (492 sloc) 20.9 KB
<?php $this->config = new Zend_Config_Ini('../application/configs/application.ini', 'production'); ?>
<?php if (!$this->isForExport) { ?>
<script type="text/javascript">
$(document).ready(function() {
$('#terms, .terms').click(function() {
window.open('welcome/terms', 'terms', 'width=639,height=424,scrollbars=1');
return false;
window._gaq.push(['_trackEvent', 'Terms', 'Click', 'Terms of Use',1]); // Analytics based on Dan Short's TiggerTagger.docx document
});
});
</script>
<div id="share" class="share-bar">
<!-- header -->
<h2>The view of my digital life.</h2>
<!-- save button -->
<form id="saveResults" class="save" action="/analysis/image" method="post" style="display: inline;"> <!-- Analytics based on id #saveResults -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<button type="submit"><span>SAVE</span></button>
</form>
<div class="share-buttons">
<h3>Share:</h3>
<!-- facebook share button -->
<form id="facebookShare" class="facebook" name="facebookShare" action="/share/facebookshare" method="post" style="display: inline;"> <!-- Analytics based on id #facebookShare -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<input type="hidden" name="name" value="<?php echo $this->firstName; ?>" />
<button type="submit"><span>share to facebook</span></button>
</form>
<!-- twitter share button -->
<form id="twitterShare" class="twitter" name="facebookShare" action="/share/twittershare" method="post" style="display: inline;"> <!-- Analytics based on id #twitterShare -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<button type="submit"><span>share to twitter</span></button>
</form>
<!-- tumblr share button -->
<form id="tumblrShare" class="tumblr" name="tumblrShare" action="/share/tumblrshare" method="post" style="display: inline;"> <!-- Analytics based on id #tumblrShare -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<button type="submit"><span>share to tumblr</span></button>
</form>
<!-- Google+ share button -->
<div class="google">
<div class="g-plusone" data-size="standard" data-count="false" data-href="<?php echo $this->config->sharing->google->url; ?>">
<!-- Place this tag where you want the +1 button to render -->
<g:plusone annotation="none"></g:plusone>
<!-- Google+ Plus One Scripts -->
<script type="text/javascript">
(function() {
var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
po.src = 'https://apis.google.com/js/plusone.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
})();
</script>
</div>
</div>
</div>
<img src="/images/intel-logo-blue-small.png" alt="Intel" />
</div>
<? } ?>
<!--[if IE 8]><!-- IE 8 does not apply stylesheets to elements rendered via AJAX - inline styles are read -->
<style>
<?php
$domain = $_SERVER['SERVER_NAME'];
$port = $_SERVER['SERVER_PORT'];
if ($port != '80') {
$port = ':' . $port;
} else {
$port = '';
}
?>
<?php echo str_replace('/images/', 'http://' . $domain . $port . '/images/', $this->IE8Styles); ?><? /* str_replace is fix for documented IE bug: http://support.microsoft.com/kb/937266 */ ?>
</style>
<![endif]-->
<div id="analysisIE8Wrapper">
<div class="header">
<div class="title">
<div class="profileImages <?php if (count($this->profileImages) == 1) { echo 'one'; } else if (count($this->profileImages) == 2) { echo 'two'; } else if (count($this->profileImages) == 3) { echo 'three'; } ?>"><!-- FIXME add class of 'one' or 'two' if we have less than three profile images -->
<?php foreach ($this->profileImages as $profileImage) { ?>
<div class="profile">
<div class="imageContainer">
<img src="<?php echo $profileImage['url']; ?>" alt="avatar" />
</div>
<div class="network <?php echo $profileImage['network']; ?>">&nbsp;</div>
</div>
<? } ?>
</div>
<div class="headerBylineContainer">
<h1 class="whatAboutMe">&nbsp;</h1>
<?php if ($this->firstName) { ?>
<div class="byline">By <?php echo $this->firstName; ?></div>
<? } ?>
</div>
</div>
<div class="date">
<?php echo $this->currentDate; ?>
</div>
</div>
<!-- THE STORIES I TELL -->
<div class="section" id="passionMap">
<div class="header">
<div class="h2Holder"><h2>The Stories I Tell</h2></div>
<div class="h3Holder"><h3>My favorite topics</h3></div>
</div>
<div class="article">
<?php
if (count($this->passionMap['latestPosts']) > 5) {
$col1Posts = array_slice($this->passionMap['latestPosts'], 0, 5);
$col2Posts = array_slice($this->passionMap['latestPosts'], 5, 5);
} else {
$col2Posts = $this->passionMap['latestPosts'];
}
?>
<?
// DEV
//unset($col1Posts);
//unset($col2Posts);
?>
<div class="posts"> <!-- FIXME replace with real posts -->
<?php if (isset($col2Posts)) { ?>
<?php if (isset($col1Posts)) { ?>
<? foreach ($col1Posts as $post) { ?>
<div class="post <?php if ($post['type'] == 'photo') { ?> image<? } ?>">
<div class="network <?php echo $post['network']; ?>"></div>
<? if ($post['type'] == 'photo') { ?>
<img src="<?=$post['url']?>" alt="post" />
<? } ?>
<p class="<?php echo $post['category']; ?>">
<?=stripslashes(stripslashes($post['text']))?>
</p>
</div>
<? } ?>
<? } else { ?>
<div class="error">
<p class="lowPostsCol1">Category Stealth!</p>
<p class="lowPostsCol1">You may talk about these categories, but you've managed to evade their common key words.</p>
</div>
<? } ?>
<? } else { ?>
<div class="error">
<p class="noPostsCol1">Category Stealth!</p>
</div>
<? } ?>
</div>
<!-- passion map graphic -->
<div class="graphic">
<div id="passionMapGraphic"></div>
<div id="passionMapOverlay"></div>
</div>
<div class="posts">
<?php if (isset($col2Posts)) { ?>
<? foreach ($col2Posts as $post) { ?>
<div class="post <?php if ($post['type'] == 'photo') { ?> image<? } ?>">
<div class="network <?php echo $post['network']; ?>"></div>
<? if ($post['type'] == 'photo') { ?>
<img src="<?=$post['url']?>" alt="post" />
<? } ?>
<p class="<?php echo $post['category']; ?>">
<?=stripslashes(stripslashes($post['text']))?>
</p>
</div>
<? } ?>
<? } else { ?>
<div class="error">
<p class="noPostsCol2">You may talk about these categories, but you've managed to evade their common key words!</p>
</div>
<? } ?>
</div>
</div>
<?php // browsers have difficultly rendering SVG over ajax - so instead we are using PHP to load json-encoded data into a div, then once the analysis page is loaded, run a javascript call that parses that data and builds the chart ?>
<?php
$colors = array(
'art-photo' => '#00aeef',
'fashion' => '#0071c7',
'food' => '#014380',
'gaming' => '#3e5801',
'music' => '#729b00',
'science' => '#a5e33a',
'shopping' => '#fee554',
'sports' => '#fdba13',
'study' => '#ff7c14',
'tech' => '#ff0101',
'travel' => '#c20000',
'tv-film' => '#82003e',
);
?>
<div id="categoryDataContainer" class="dataContainer"><?php echo json_encode($this->passionMap['scores']); ?></div>
<div id="colorsDataContainer" class="dataContainer"><?php echo json_encode($colors); ?></div>
</div>
<div id="centerSectionWrapper">
<div class="col1">
<div class="section" id="friendFave">
<div class="h2Holder"><h2>Friend Fave</h2></div>
<div class="h3Holder"><h3>Most popular update</h3></div>
<div class="article">
<?php //$this->mostPopularPost = NULL; // DEV ?>
<?php if ($this->mostPopularPost != NULL) { ?>
<div class="post">
<div class="network facebook"></div>
<p>
<strong class="likes"><?php echo $this->mostPopularPost['likes']; ?> Likes</strong>
<p class="<?php echo $this->mostPopularPost['category']; ?>">
<?php echo $this->mostPopularPost['text']; ?>
</p>
</p>
</div>
<?php } else { ?>
<p class="error">You either have shy friends, or you need to get out there and post more!</p>
<? } ?>
</div>
</div>
<div class="section" id="swoonworthy">
<div class="h2Holder"><h2>Swoonworthy</h2></div>
<div class="h3Holder"><h3>Most popular pic</h3></div>
<div class="article">
<?php // $this->mostPopularPhoto = NULL; // DEV ?>
<?php if ($this->mostPopularPhoto != NULL) { ?>
<div class="post image">
<div class="network facebook"></div>
<p class="<?php echo $this->mostPopularPhoto['category']; ?>">
<strong class="likes"><?php echo $this->mostPopularPhoto['likes']; ?> Likes</strong><br />
<img src="<?php echo $this->mostPopularPhoto['url']; ?>" alt="post" />
<?php echo $this->mostPopularPhoto['text']; ?>
</p>
</div>
<? } else { ?>
<p class="error">Less talk, more pics!</p>
<? } ?>
</div>
</div>
<div class="section" id="whenIClockIn">
<div class="header">
<div class="h2Holder"><h2>When I clock In</h2></div>
<div class="h3Holder"><h3>My chat light is on!</h3></div>
</div>
<div class="article">
<?php
// DEV
//$this->dayNight['day'] = 100;
//$this->dayNight['night'] = 100;
?>
<div class="day <?php if ($this->dayNight['day'] == 100) { echo 'wide'; } ?>"><!-- add class 'wide' if valus is 100% -->
<?php echo $this->dayNight['day']; ?><sup>%</sup>
</div>
<div class="doIPost">
Do I post more after sunrise or after sunset?
</div>
<div class="night <?php if ($this->dayNight['night'] == 100) { echo 'wide'; } ?>"><!-- add class 'wide' if valus is 100% -->
<?php echo $this->dayNight['night']; ?><sup>%</sup>
</div>
</div>
</div>
</div>
<div class="col2">
<div class="section" id="howIPutItOutThere">
<div class="header">
<div class="h2Holder"><h2>How I put it out There</h2></div>
<div class="h3Holder">&nbsp;</div>
</div>
<div class="article">
<div class="madeIt">
<div class="barWrapper">
<?php $percent = $this->socialStyle['creator']['score']; ?>
<div class="bar" style="width: <? echo ($percent * .01 * 340); ?>px;">&nbsp;</div> <!-- max width is 340, min width is 5 -->
<div class="percent"><?php echo $percent; ?>%</div>
</div>
<div class="wrapper">
<div class="labelWrapper">
<div class="label">Made It. Thoughts and work I've posted.</div>
</div>
<?php if (($this->socialStyle['creator']['post'] != NULL) || (($this->socialStyle['creator']['post']['text'] == NULL) && ($this->socialStyle['creator']['post']['url'] == NULL))) { ?>
<div class="post <?php if ($this->socialStyle['creator']['post']['url'] != NULL) { echo 'image'; } ?>">
<div class="network <?php echo $this->socialStyle['creator']['post']['network']; ?>"></div>
<?php if ($this->socialStyle['creator']['post']['url'] != NULL) { ?>
<img src="<?php echo $this->socialStyle['creator']['post']['url'] ?>" alt="post" />
<? } ?>
<p class="<?php echo $this->socialStyle['creator']['post']['category']; ?>">
<?php echo $this->socialStyle['creator']['post']['text']; ?>
</p>
</div>
<? } ?>
</div>
</div>
<div class="foundIt">
<div class="barWrapper">
<?php $percent = $this->socialStyle['curator']['score']; ?>
<div class="bar" style="width: <? echo ($percent * .01 * 340); ?>px;">&nbsp;</div> <!-- max width is 340, min width is 5 -->
<div class="percent"><?php echo $percent; ?>%</div>
</div>
<div class="wrapper">
<div class="labelWrapper">
<div class="label">Found It. Thoughts and work of others I&#39;ve shared.</div>
</div>
<?php if (($this->socialStyle['curator']['post'] != NULL) || (($this->socialStyle['curator']['post']['text'] == NULL) && ($this->socialStyle['curator']['post']['url'] == NULL))) { ?>
<div class="post <?php if ($this->socialStyle['curator']['post']['url'] != NULL) { echo 'image'; } ?>">
<div class="network <?php echo $this->socialStyle['curator']['post']['network']; ?>"></div>
<?php if ($this->socialStyle['curator']['post']['url'] != NULL) { ?>
<img src="<?php echo $this->socialStyle['curator']['post']['url'] ?>" alt="post" />
<? } ?>
<p class="<?php echo $this->socialStyle['curator']['post']['category']; ?>">
<?php echo $this->socialStyle['curator']['post']['text']; ?>
</p>
</div>
<? } ?>
</div>
</div>
<div class="likedIt">
<div class="barWrapper">
<?php $percent = $this->socialStyle['fan']['score']; ?>
<div class="bar" style="width: <? echo ($percent * .01 * 340); ?>px;">&nbsp;</div> <!-- max width is 340, min width is 5 -->
<div class="percent"><?php echo $percent; ?>%</div>
</div>
<div class="wrapper">
<div class="labelWrapper">
<div class="label">Liked it. Thoughts and work of others I've liked and favorited.</div>
</div>
<?php if (($this->socialStyle['fan']['post'] != NULL) || (($this->socialStyle['fan']['post']['text'] == NULL) && ($this->socialStyle['fan']['post']['url'] == NULL))) { ?>
<div class="post <?php if ($this->socialStyle['fan']['post']['url'] != NULL) { echo 'image'; } ?>">
<div class="network <?php echo $this->socialStyle['fan']['post']['network']; ?>"></div>
<?php if ($this->socialStyle['fan']['post']['url'] != NULL) { ?>
<img src="<?php echo $this->socialStyle['fan']['post']['url'] ?>" alt="post" />
<? } ?>
<p class="<?php echo $this->socialStyle['curator']['post']['category']; ?>">
<?php echo $this->socialStyle['fan']['post']['text']; ?>
</p>
</div>
<? } ?>
</div>
</div>
</div>
</div>
<div class="section" id="myMood">
<div class="header">
<div class="h2Holder"><h2>My Mood</h2></div>
<div class="h3Holder">
<h3>My words, my tone</h3>
<div class="data">
<?php
if (is_numeric($this->outlook)) {
$percentage = $this->outlook;
} else {
$percentage = 0;
}
$pos = ($percentage * .01) * 74; // 74 is number of pixels from center to either side of graphic
?>
<div class="arrow" style="position: relative; left: <?=$pos; ?>px;">&nbsp;</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="section" id="essentials">
<div class="header">
<div class="h2Holder"><h2>The Essentials</h2></div>
<div class="h3Holder"><h3>Who I talk to most, where and when</h3></div>
</div>
<div class="article">
<?php
$num = 5;
switch (count($this->relationships)) {
case 5:
$num = 'five';
break;
case 4:
$num = 'four';
break;
case 3:
$num = 'three';
break;
case 2:
$num = 'two';
break;
case 1:
$num = 'one';
break;
case 0:
$num = 'zero';
break;
}
?>
<div class="relationshipContainer <?php echo $num; ?>"><!-- add class 'one', 'two', etc., for number of relationships shown -->
<?php if (count($this->relationships)) { ?>
<?php foreach ($this->relationships as $profile) { ?>
<div>
<div class="iconImageWrapper">
<div class="icons">
<div class="network <?=$profile['network']?>"></div>
<div class="dayNightIcon <?=$profile['dayNight']?>"></div>
<?php if ($profile['category'] != NULL) { ?>
<div class="categoryIcon <?php echo $profile['category']; ?>"></div>
<? } else { ?>
<div class="categoryIcon none"></div>
<? } ?>
</div>
<img src="<?=$profile['pic']?>" alt="post" />
</div>
<div class="zodiacContainer">
<div class="zodiacIcon <?=strtolower($profile['zodiac'])?>"></div>
<p><?=$profile['zodiac']?>&#45;<?=$profile['birthday']?></p>
</div>
</div>
<? } ?>
<? } else { ?>
You don't seem to talk<br />directly to your friends
<? } ?>
</div>
</div>
</div>
<div class="section" id="whatImTalkingAboutNow">
<div class="header">
<div class="h2Holder"><h2>What I&#39;m talking about right now</h2></div>
<div class="h3Holder"><h3>My latest posts</h3></div>
</div>
<div class="article">
<?php
$num = 'three';
switch (count($this->latestPosts)) {
case 2:
$num = 'two';
break;
case 1:
$num = 'one';
break;
}
?>
<div class="postWrapper <?php echo $num; ?>"> <!-- add class 'one', 'two', or 'three' depending on number of posts shown -->
<?php foreach ($this->latestPosts as $post) { ?>
<div class="post <?php if ($post['url'] != NULL) { echo 'image'; } ?>">
<div class="network <?php echo $post['network']; ?>"></div>
<?php if ($post['url'] != NULL) { ?>
<img src="<?php echo $post['url']; ?>" alt="post" />
<? } ?>
<p class="<?php echo $post['category']; ?>">
<?php echo $post['text'] ?>
</p>
</div>
<? } ?>
<div class="cta">
How will my story change? Come back and find out.
</div>
</div>
</div>
</div>
<div class="footer">
<div class="cta2">Inspired? Visit intel.com/inteledge or follow is @intelEdge on Twitter</div>
<p>&copy;2012, Intel Corporation. All rights reserved. Intel, the Intel logo and Ultrabook are trademarks of Intel Corporation in the U.S. and/or other countries.</p>
<div class="ultrabook">Ultrabook(TM) Inspired by Intel(R)</div>
</div>
<?php if (!$this->isForExport) { ?>
<div id="share-footer" class="share-bar">
<!-- save button -->
<form id="saveResults-footer" class="save" action="/analysis/image" method="post" style="display: inline;"> <!-- Analytics based on id #saveResults -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<button type="submit"><span>SAVE</span></button>
</form>
<div class="share-buttons">
<h3>Share:</h3>
<!-- facebook share button -->
<form id="facebookShare-footer" class="facebook" name="facebookShare" action="/share/facebookshare" method="post" style="display: inline;"> <!-- Analytics based on id #facebookShare-footer -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<input type="hidden" name="name" value="<?php echo $this->firstName; ?>" />
<button type="submit"><span>share to facebook</span></button>
</form>
<!-- twitter share button -->
<form id="twitterShare-footer" class="twitter" name="facebookShare" action="/share/twittershare" method="post" style="display: inline;"> <!-- Analytics based on id #twitterShare-footer -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<button type="submit"><span>share to twitter</span></button>
</form>
<!-- tumblr share button -->
<form id="tumblrShare-footer" class="tumblr" name="tumblrShare" action="/share/tumblrshare" method="post" style="display: inline;"> <!-- Analytics based on id #tumblrShare-footer -->
<input type="hidden" name="myData" value="<?=$this->exportParams?>" />
<button type="submit"><span>share to tumblr</span></button>
</form>
<!-- Google+ share button -->
<div class="google">
<div class="g-plusone" data-size="standard" data-count="false" data-href="<?php echo $this->config->sharing->google->url; ?>">
<!-- Place this tag where you want the +1 button to render -->
<g:plusone annotation="none"></g:plusone>
<!-- Google+ Plus One Scripts -->
<script type="text/javascript">
(function() {
var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
po.src = 'https://apis.google.com/js/plusone.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
})();
</script>
</div>
</div>
</div>
</div>
<div class="licensing-links">
<a href="#" id="terms">Terms of Use</a> | <a href="http://www.intel.com/privacy" target="_blank">Privacy Policy</a>
</div>
</div>
<? } ?>