The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Other wordpress plugin css and js file not working

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
  • #256560

    i tried to make a simple plugin and for that include some css and js (which is inside css and js folder like wp-content/plugin/css/theme.css) but it’s not working and also showing in view-source (ctrl +u) and not giving any error either..

    i copy some code from stack overflow article,

    function testi_register_style(){
        wp_register_style('testi-theme-css', plugins_url('css/theme.css', __FILE__), array(), '1.0.0');
    add_action('admin_init', 'testi_register_style');
    function testi_enqueue_style(){

    what’s wrong in there? and anything i need to add in child-theme or parent-theme function.php file?
    please help..

Viewing 1 post (of 1 total)
  • The forum ‘Other’ is closed to new topics and replies.