• Resolved judyosh

    (@judyosh)


    Kept getting 404 Errors — the index and another page is fine, everything else is down. I ran Debug This, Server > File Permissions and got the following:

    Notice: Undefined offset: 1 in C:\xampp\htdocs\wordpress\wp-content\plugins\debug-this\debug-this.php on line 204
    Debug This Mode: file-permissions – Info about WP root, plugins and theme directories.

    POSIX missing

    Notice: Trying to get property of non-object in C:\xampp\htdocs\wordpress\wp-content\plugins\Divi_Builder_[v2.0.1]\includes\builder\functions.php on line 6356

    Undefined offset in line 204, no posix and the Divi Builder non-object. Line 6356 reads: if ( ! current_user_can( ‘edit_post’, $current_object->ID ) ) {return;}

    Not really sure what to do about this. Tried just about everything before I tried Debug This (reset permalinks, disabled plugins, etc.). Very perplexed as to why one non-index page (I use Divi Builder there, too) is up and the rest down. I was ready to deploy and now this. Any ideas, thoughts or suggestions are most appreciated.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Contributor Chris Dillon

    (@cdillon27)

    Hi Judy,

    The first notice about POSIX is harmless.

    The second notice would not cause a 404 itself but it does indicate that an error occurred somewhere which mangled the main query object which would cause a 404.

    Divi Builder tripped over it but that doesn’t mean it caused it. In fact, I just tested version 2.0.1 on a clean install with no problems.

    So the theme or a plugin is causing the 404’s.

    I suggest you enable debugging in WordPress.
    https://codex.www.ads-software.com/Debugging_in_WordPress

    If you’ve already tried deactivating plugins then the culprit may be your theme. Test with TwentySeventeen.

    Let me know what you find.

    Chris

    Thread Starter judyosh

    (@judyosh)

    Seems that some changes I had made to global.js were causing the Divi Builder issue, because when I reverted back to the original, they went away from the Server > File Permissions (Posix still there) & debug logs. The only thing that’s showing in debug.log now is:

    PHP Notice: Undefined offset: 1 in C:\xampp\htdocs\wordpress\wp-content\plugins\debug-this\debug-this.php on line 204

    However, I’m still getting the page not found/404 on some of the pages (backend is okay). I deactivated all the plugins and switched themes, so that’s not it. Savequeries & ScriptDebug enabled, but I’m not sure what queries to run as I’m a designer, not a programmer. Still wondering what I could have done to cause this, as everything was working fine. Went thru any files I may have edited in my quest to increase max file upload size (that’s how I discovered the global.js change).

    Not sure what else to run diagnostically that would provide any more clues. Thanks again so much for your help.

    Plugin Contributor Chris Dillon

    (@cdillon27)

    The “Undefined offset” notice is totally within Debug This. The plugin is not as robust as it could be in handling certain unlikely conditions. If you were to deactivate the plugin but keep debugging enabled, you would not see the notice.

    Can you give me an example of a URL that works and one that doesn’t?

    Thread Starter judyosh

    (@judyosh)

    Within Twenty Seventeen, in the Customization menu you have the ability to create a static homepage and add new pages in that menu item. When not logged in, all of the pages that I created there (index/home, 404, about, etc.) are showing up. However, any of the other pages that were created thru the Dashboard > Pages > add new, are not showing up at all.

    The backend seems fine and all pages are visible. All of my permalinks are set to the page name. Everything else seems pretty much straightforward. A working url is localhost/wordpress/about and a non-working one is localhost/wordpress/messages.

    Would there be a permissions issue if the only the Customizations created pages were appearing? I’m wondering why only these pages show up and the other dashboard pages don’t…

    Plugin Contributor Chris Dillon

    (@cdillon27)

    Just to confirm, the pages created via Dashboard > Pages are published (not drafts) and public with a published date sometime in the past?

    Let’s check the rewrite rules. This plugin works well despite the scary “hasn’t been updated in over 2 years” warning.
    https://www.ads-software.com/plugins/rewrite-rules-inspector/

    Go to Tools > Rewrite Rules, enter a URL that works and click Filter. You should get a result like:
    index.php?pagename=$matches[1]&page=$matches[2]

    Then enter a URL that doesn’t work and compare the results. If they match exactly, your rewrite rules are OK.

    Thread Starter judyosh

    (@judyosh)

    I don’t know why, but I could have sworn all my pages were working when logged out — didn’t even think to check if they were draft or not. Thank you so much, Chris, you saved me! Do you a bitcoin tip jar anywhere? You really should consider getting one!

    Judy

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘File Permissions error log’ is closed to new replies.