Support » Plugin: Autoptimize » Enable 404 fallbacks option – code issue

  • Resolved AITpro

    (@aitpro)


    On 3 separate sites on 3 different host servers the Enable 404 fallbacks option code below is not creating the ErrorDocument 404 line of htaccess code in the Autoptimize cache folder htaccess file.

                if ( self::do_fallback() === true ) {
                    $content .= "\nErrorDocument 404 " . trailingslashit( parse_url( content_url(), PHP_URL_PATH ) ) . 'autoptimize_404_handler.php';
                }
                @file_put_contents( $htaccess, $content ); // @codingStandardsIgnoreLine
Viewing 7 replies - 16 through 22 (of 22 total)
  • So yeah if the checkbox is checked and the DB option does not exist then it cannot have a value of: 1. In other words, the checkbox should not be checked if the DB option does not exist yet. πŸ˜‰

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    Well, did you test the beta already AITpro? πŸ™‚

    Is the Beta version the version on GitHub? I do all of all my stuff inhouse now since GitHub has been problematic for me in the past.

    • This reply was modified 1 month, 1 week ago by AITpro.
    Plugin Author Optimizing Matters

    (@optimizingmatters)

    yeah, but you can simply download the zip-file from https://github.com/futtta/autoptimize/archive/beta.zip πŸ™‚

    Cool! Will post my results after Beta testing. Sorry about not seeing your previous replies about testing the Beta version. I was posting replies at the same time and did not see your other replies. πŸ˜‰

    • This reply was modified 1 month, 1 week ago by AITpro.

    The Beta version works perfectly. The ErrorDocument line of htaccess code is succesfully written in the AO htaccess file. πŸ™‚

    Deleted the AO plugin using the standard Plugin page deletion.
    All DB options are removed.
    Manual AO Beta plugin installation.
    AO plugin activation: The ErrorDocument line of htaccess code is successfully created in the AO htaccess file.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    super, this will be in the next version! thanks for reporting & testing so extensively aitpro ! πŸ™‚

Viewing 7 replies - 16 through 22 (of 22 total)
  • You must be logged in to reply to this topic.