Support » Plugin: Default Blog » [Plugin: Default Blog] broken path to css file

  • Resolved arstropica

    (@arstropica)


    Line 6 of the functions_layout.inc.php file in /ui directory contains a function (defblog_css) that declares a path to a styles.css file in the same directory. The path is based on a concatenation of the site url, the wordpress plugin directory and the directory name of the script calling the function. It does not account for the default blog plugin directory. An easier way to declare a path to the css file is the pathinfo function as posted below:

    function defblog_css(){
        $defblog_plugin_path=str_replace(ABSPATH, '',pathinfo(__FILE__, PATHINFO_DIRNAME));
        echo "<link rel=\"stylesheet\" href=\"".get_option('siteurl')."/".$defblog_plugin_path."/styles.css\" type=\"text/css\" media=\"screen\" />";
    }

    Hope this is helpful to anyone that needs it.

    http://wordpress.org/extend/plugins/default-blog-options/

  • The topic ‘[Plugin: Default Blog] broken path to css file’ is closed to new replies.