Adding profile links.
This commit is contained in:
1 parent
e42fe70f64
commit
2f1c8d5e24
4 files changed
+46
-53
No files matched your search
@@ -99,6 +99,10 @@ body.dns {
|
|||||||
text-indent:-9999px;
|
text-indent:-9999px;
|
||||||
width:575px;
|
width:575px;
|
||||||
}
|
}
|
||||||
|
.profile-info {
|
||||||
|
display:block;
|
||||||
|
text-align:right;
|
||||||
|
}
|
||||||
#menu {
|
#menu {
|
||||||
position:absolute;
|
position:absolute;
|
||||||
bottom:35px;
|
bottom:35px;
|
||||||
@@ -566,6 +570,7 @@ img {
|
|||||||
display:block;
|
display:block;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.list-group,
|
||||||
.panel {
|
.panel {
|
||||||
margin-bottom: 1.5em;
|
margin-bottom: 1.5em;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,21 +10,6 @@ class Navigation {
|
|||||||
<a class="home-link" href="http://inside.studentersamfundet.no/">Hjem</a>
|
<a class="home-link" href="http://inside.studentersamfundet.no/">Hjem</a>
|
||||||
<ul id="navList">
|
<ul id="navList">
|
||||||
|
|
||||||
<?php
|
|
||||||
if(checkAuth("view-menu-quick")){
|
|
||||||
?>
|
|
||||||
<li class="menulist">
|
|
||||||
<a href="#" id="quickSwitch" class="switch">Personlig</a>
|
|
||||||
<ul id="quickMenu" class="menu">
|
|
||||||
<li><a href="index.php?page=display-current-user">Oppdatér brukerinformasjon</a></li>
|
|
||||||
<?php if (!isMember(getCurrentUser())){?>
|
|
||||||
<li><a href="index.php?page=register-membership">Kjøp/registrér medlemskap</a></li>
|
|
||||||
<?php }else if (membershipExpired(getCurrentUser())){?>
|
|
||||||
<li><a href="index.php?page=register-membership">Aktiver medlemskap</a></li>
|
|
||||||
<?php } ?>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<?php }?>
|
|
||||||
<?php
|
<?php
|
||||||
/* Note: This menu item is hidden because the feature is not used anymore */
|
/* Note: This menu item is hidden because the feature is not used anymore */
|
||||||
/*if(checkAuth("view-menu-messages")){
|
/*if(checkAuth("view-menu-messages")){
|
||||||
|
|||||||
+16
-38
@@ -70,6 +70,22 @@ class Page {
|
|||||||
</div>
|
</div>
|
||||||
</noscript>
|
</noscript>
|
||||||
<?php
|
<?php
|
||||||
|
if ( getCurrentUser() ) {
|
||||||
|
$user = new User( getCurrentUser() );
|
||||||
|
?>
|
||||||
|
<div class="profile-info">
|
||||||
|
<span class="gravatar">
|
||||||
|
<?php echo get_gravatar( $user->email , 20 , 'mm' , 'g' , true ); ?>
|
||||||
|
</span>
|
||||||
|
<span class="username">
|
||||||
|
<a href="index.php?page=display-current-user"><?php echo( "$user->firstname; $user->lastname" ); ?></a>
|
||||||
|
</span>
|
||||||
|
<span class="logout">
|
||||||
|
(<a href="index.php?action=log-out">Logg ut</a>)
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
if (checkAuth("view-" . $this->page) || checkResponsible()){
|
if (checkAuth("view-" . $this->page) || checkResponsible()){
|
||||||
|
|
||||||
@@ -595,44 +611,6 @@ class Page {
|
|||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
|
||||||
if(time() < 1315612799):
|
|
||||||
?>
|
|
||||||
<style type="text/css">
|
|
||||||
#lol
|
|
||||||
{
|
|
||||||
margin:10px 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#lol:after
|
|
||||||
{
|
|
||||||
content:".";
|
|
||||||
clear:both;
|
|
||||||
height:0px;
|
|
||||||
display:block;
|
|
||||||
visibility:hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
#lol .half
|
|
||||||
{
|
|
||||||
width:45%;
|
|
||||||
float:left;
|
|
||||||
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
<div id="lol">
|
|
||||||
<div class="half">
|
|
||||||
<h3>Ny i DNS?</h3>
|
|
||||||
|
|
||||||
<p>Har du lyst til å være med å vår egen lille fadderhelg 9.-11. september? Bli kjent med Det Norske Studentersamfund og vi som holder til der! Se <a href="http://studentersamfundet.no/nyidns.php">ny i dns!</a></p>
|
|
||||||
</div>
|
|
||||||
<div class="half">
|
|
||||||
<h3>Bli aktiv!</h3>
|
|
||||||
<p>Syns du noe av det vi holder på med er spennende? Lyst til å booke band eller lære å mikse drinker? Bli med oss som aktiv i en av de mange foreningene på huset, du får garantert minner for livet og nye venner!<br /> Se <a href="http://studentersamfundet.no/bliaktiv.php">bli aktiv!</a></p>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<?php endif;
|
|
||||||
if (!isActive()){?>
|
if (!isActive()){?>
|
||||||
<?php
|
<?php
|
||||||
if (!isMember()){?>
|
if (!isMember()){?>
|
||||||
|
|||||||
@@ -1663,4 +1663,29 @@ function site_root() {
|
|||||||
return $url;
|
return $url;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get either a Gravatar URL or complete image tag for a specified email address.
|
||||||
|
*
|
||||||
|
* @param string $email The email address
|
||||||
|
* @param string $s Size in pixels, defaults to 80px [ 1 - 2048 ]
|
||||||
|
* @param string $d Default imageset to use [ 404 | mm | identicon | monsterid | wavatar ]
|
||||||
|
* @param string $r Maximum rating (inclusive) [ g | pg | r | x ]
|
||||||
|
* @param boole $img True to return a complete IMG tag False for just the URL
|
||||||
|
* @param array $atts Optional, additional key/value attributes to include in the IMG tag
|
||||||
|
* @return String containing either just a URL or a complete image tag
|
||||||
|
* @source http://gravatar.com/site/implement/images/php/
|
||||||
|
*/
|
||||||
|
function get_gravatar( $email, $s = 80, $d = 'mm', $r = 'g', $img = false, $atts = array() ) {
|
||||||
|
$url = 'http://www.gravatar.com/avatar/';
|
||||||
|
$url .= md5( strtolower( trim( $email ) ) );
|
||||||
|
$url .= "?s=$s&d=$d&r=$r";
|
||||||
|
if ( $img ) {
|
||||||
|
$url = '<img src="' . $url . '"';
|
||||||
|
foreach ( $atts as $key => $val )
|
||||||
|
$url .= ' ' . $key . '="' . $val . '"';
|
||||||
|
$url .= ' />';
|
||||||
|
}
|
||||||
|
return $url;
|
||||||
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
Reference in new issue
Block a user