Enter icons in WordPress from css

0

I'm trying to enter FontAwesome icons in my WordPress template but the moment I see the template in the browser, they are not displayed

in my css I put them in the following way:

nav.sociales li a[href*="facebook.com"]::before {
    content: '\f09a';
}
nav.sociales li a[href*="youtube.com"]::before {
    content: '\f16a';
}
nav.sociales li a[href*="instagram.com"]::before {
    content: '\f16d';
}

in my functions.php file:

wp_register_style('fotawesome', get_template_directory_uri() . 'css/font-awesome.min.css', array('normalize'), '4.7.0');

and that's how they are displayed

I gave him to inspect the element in case there was an error that he showed me in the console, but it does not mark anything, can someone tell me what my error is?

Part where the icons are displayed

<!-- Inicio Redes Sociales -->
        <div class="informacion-encabezado">
            <div class="redes-sociales">
                <?php 
                    $args = array(
                        'theme_location' => 'social-menu',
                        'container' => 'nav',
                        'container_class' => 'sociales',
                        'container_id' => 'sociales',
                        'link_before' => '<span class="sr-text">',
                        'link_after' => '</span>'
                    );
                    wp_nav_menu($args);             
                ?>
            </div>
    <!-- Final Redes Sociales -->
    
asked by cesg.dav 31.08.2017 в 00:50
source

1 answer

0

You have to change it for:

nav.sociales li a[href*="instagram.com"] i::before {
    content: '\f16d';
}

Since i is used to display the icons:

After you get up and running, you can place Font Awesome icons just about anywhere with the <i> tag.

Source: link

    
answered by 31.08.2017 в 01:09