• Resolved philzm

    (@philzm)


    in sharify-style.php the code at the top assumes that you are using a “traditional” wordpress install.

    $absolute_path = explode('wp-content', $_SERVER['SCRIPT_FILENAME']);
     $wp_load = $absolute_path[0] . 'wp-load.php';
     require_once($wp_load);

    The issue with this is if you set your WP_CONTENT_DIR to be somewhere else this will fail. So for example you have wordpress in a folder called “cms” and your content is in another folder called “content” (which would contain uploads / themes / plugins).

    I would recommend changing the way this is done.

    Maybe what you could do is rather than enqueuing the sharify-style.php as a style is to instead just wrap all the css in a function and then inject it into the head as inline css. Something like this (sharify.php http://pastebin.com/6HFK5T33) (sharify-style.php http://pastebin.com/82qMddeg)

    https://wordpress.org/plugins/sharify/

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘plugin assumes content directory in sharify-style.php’ is closed to new replies.