Created
September 11, 2014 12:42
-
-
Save ellenmva/14e922ca5b70cabd6e93 to your computer and use it in GitHub Desktop.
Add Cimy User Extra Fields Single Bits
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@facebook: #3B5998; | |
@twitter: #00ACED; | |
.author-links { | |
text-align: center; | |
a { | |
margin-right: 10px; // Here in-case you wish to add margins | |
padding: 0px; // Here in-case you wish to add padding | |
} | |
li { | |
display: inline; | |
} | |
.fa { | |
.border-radius(0px); // Here in-case you wish to add a radius | |
margin-bottom: 5px; | |
min-width: 30px; | |
color: #FFF; | |
text-align: center; | |
font-size: 18px; | |
line-height: 30px; | |
&:hover { .transition(background 400ms linear); } | |
} | |
.fa-facebook { | |
background-color: @facebook; | |
&:hover { background-color: lighten(@facebook, 10%); } | |
} | |
.fa-twitter { | |
background-color: @twitter; | |
&:hover { background-color: lighten(@twitter, 10%); } | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$facebook = get_cimyFieldValue(get_the_author_meta( 'ID' ), 'FACEBOOK'); | |
$twitter = get_cimyFieldValue(get_the_author_meta( 'ID' ), 'TWITTER'); | |
echo '<ul class="author-links">'; | |
if($facebook) | |
echo '<li><a href="'. cimy_uef_sanitize_content($facebook) .'" target="_blank"><i class="fa fa-facebook"></i></a></li>'; | |
if($twitter) | |
echo '<li><a href="'. cimy_uef_sanitize_content($twitter) .'" target="_blank"><i class="fa fa-twitter"></i></a></li>'; | |
echo '</ul>'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment