WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Links to plugin files not resolving (8 posts)

  1. arcware
    Member
    Posted 3 years ago #

    Has anyone seen an issue where links to plugin files can't be resolved and results in 404 errors?

    For example, I have a plugin that drops a page template into the active theme directory, and this template file references a reset.css file. The reset.css file is found in the /wp-contet/plugins/[plugin-name]/templates folder.

    Everything is fine until you create a new page with the template and then view the page; the layout is wrong. When viewing the source, I see that the link to the reset.css file is correct (http://site.com/wp-content/plugins/plugin-name/templates/reset.css), but when I put that URL in the browser it results in a "page not found" error.

    I've tried deactivating plugins, checked permissions, and turned on the debug log, but so far nothing has helped.

    Any ideas?

  2. esmi
    Forum Moderator
    Posted 3 years ago #

    Some sort of server path issue?

  3. arcware
    Member
    Posted 3 years ago #

    I thought so at first too, but it doesn't seem like it.

  4. esmi
    Forum Moderator
    Posted 3 years ago #

    Is this happening with all plugins or just one or two?

  5. arcware
    Member
    Posted 3 years ago #

    So far just the one.

  6. esmi
    Forum Moderator
    Posted 3 years ago #

    Perhaps that plugin isn't defining the plugin url correctly?

    http://codex.wordpress.org/Determining_Plugin_and_Content_Directories

  7. arcware
    Member
    Posted 3 years ago #

    Nope, I've done that correctly; otherwise, the link to the file wouldn't be correct in the first place.

  8. arcware
    Member
    Posted 3 years ago #

    Turns out the issue was due to my misunderstanding of how wordpress.org packages the plugin upon download. That caused some path issues I was not aware of, but I've tracked them down and fixed them.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags