在中心对齐锚标记内的内容

LP1*_*P13 4 css twitter-bootstrap font-awesome

我需要帮助让锚内的内容垂直对齐。我在锚标签中使用字体真棒图标和文本。我希望图标和文本在中心垂直和水平对齐。我能够进行水平对齐,但无法进行垂直对齐。不知道我错过了什么

.my-tile {
    height: 90px;
    margin-left: 0.5%;
    margin-right: 0.5%;
    float: left;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    /*display: table;*/
    border-radius: 3px;
    -moz-border-radius: 3px;
    -webkit-border-radius: 3px;    
    position: relative;    
    align-items: center;
    background: linear-gradient(#af4b17, #e57234); /* Standard syntax */
    background: -moz-linear-gradient(#af4b17, #e57234 35%, #e57234);
    background: -webkit-gradient(linear,left top,left bottom,color-stop(0, #af4b17),color-stop(.35, #e57234),color-stop(1, #e57234));
    border: 1px solid #af4b17;
    text-align: center;
    justify-content: center;
    vertical-align:middle;
}

    .my-tile > a {
        display: flex;
        align-items: center;
        justify-content: center;
        color: white;
        /*padding-bottom: 10px;*/
        text-decoration: none;
        position: relative;           
        vertical-align:middle;        
    }

        .my-tile > a .link-icon {
            color: white !important;
            font-size: 30px !important;            
            height: 1em;
            margin: 0 auto 5px;            
            width: 1em;            
            display: block;
            
        }        

.my-tile-half {
    width: 49%;
}
Run Code Online (Sandbox Code Playgroud)
<script src="https://use.fontawesome.com/releases/v5.0.9/js/all.js"></script>
<script src="https://ajax.aspnetcdn.com/ajax/bootstrap/3.3.7/bootstrap.min.js"></script>
<script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-2.1.1.min.js"></script>
<link href="https://ajax.aspnetcdn.com/ajax/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"/>
	<div class="row">
            <div class="col-md-4">
                <div class="row">
                    <div class="col-md-12">                        
                        <div class="my-tile my-tile-half">
                            <a href="#">
                                <div>
                                    <span class="fas fa-upload link-icon"></span>Upload
                                </div>
                            </a>
                        </div>
                        <div class="my-tile my-tile-half">
                            <a href="#">
                                <div>
                                    <span class="fas fa-clipboard-check link-icon"></span>Done
                                </div>
                            </a>
                        </div>
                    </div>
                </div>                
            </div>
        </div>
Run Code Online (Sandbox Code Playgroud)

The*_*ear 5

对齐内部所有内容的最佳方法<a></a>是使用FLEX

a {
    display: flex;
    align-items: center;
    justify-content: center;

    /** Use this rule if the tag has a parent with specific height */ 
    height: 100%; 
}
Run Code Online (Sandbox Code Playgroud)

检查这个演示:https : //jsfiddle.net/gkL5of1z/3/