css3 doesn't work. Can somebody help?

  • Author
    Posts
  • #43098

    I’m trying to create SNS button which are wrapped colored rectangular box. But it seems like the code of those boxes doesn’t apply to my website. It only shows up the name of SNS. Does somebody have any idea?

    On CSS, I put those codes.

    .share {margin-top : 40px;}
    .share ul {margin : 0;
        padding : 0;
        list-style : none;}
    .share li a {display : block;
        padding : 10px;
        color : #fff;
        font-size : 14px;
        text-decoration : none;
        text-align : center;}
    .share li a:hover {opacity :0.8;
        color : #fff;}
    .share li a:visited{ color: #fff;}
    .share ul:after {content : "";
        display : block;
        clear : both;}
    .tweet a{background-color : #55acee;}
    .facebook a{background-color : #315096;}
    .googleplus a{background-color : #dd4b39;}
    .hatena a{background-color : #008fde;}
    .line a{background-color: #00c300;}
    .pocket a{background-color :#f03e51;}
    .rss a{background-color: #ff8c00;}
    .feedly a{background-color: #6cc655;}
      
    .share li {float : left;
        width : 25%;
        margin : 0;
    margin-top:15px;}

    For example, I put facebook link like this.(I made sns.php on my child theme.)

    <?php
    $url_encode=urlencode(get_permalink());
    $title_encode=urlencode(get_the_title()).'|'.get_bloginfo('name');
    ?>
      
    <div class="share">
        <ul>
      
    
    <li class="facebook"><a>&t=<?php echo $title_encode;?>"  onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=300,width=600');return false;">
            <span class="icon-facebook"></span> facebook <?php if(function_exists('scc_get_share_facebook')) echo (scc_get_share_facebook()==0)?'':scc_get_share_facebook(); ?></a>
    </li>

    And I put this code on single.php.

    <?php get_template_part( ‘sns’ ); ?>

    Doesn’t this way work?

Viewing 1 post (of 1 total)

The topic ‘css3 doesn't work. Can somebody help?’ is closed to new replies.