• Resolved @Wp_Learn

    (@shubhamkumar)


    Hello ,

    I am new in wordpress, just Setup and configure wp locally , Try to create theme

    What I current have custom files.

    index.php
    style.css
    header.php
    footer.php
    function.php

    basic structure were working well until i create function.php and use wp enqueue style function

    <?php
    
    function learn(){
    
     wp_enqueue_style('style',get_stylesheet_uri());
    }
    add_action('wp_enqueue_scripts','learn');

    I don’t know how to use it .. Please help me so that my style.css updates will visible.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The code for setting up your stylesheet include is fine, but what stands otu is that the file is supposed to be called functions.php (with an ‘s’), not function.php. Unless the file is named correclty it won’t be included, and your PHP code won’t be run.

    Thread Starter @Wp_Learn

    (@shubhamkumar)

    Thank you very much Sir/Ma’am.

    Resolved :3

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Issue to use wp enqueue style use’ is closed to new replies.