Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter fastwordpress

    (@fastwordpress)

    Plugin Support qtwrk

    (@qtwrk)

    Hi,

    Could you please specify little bit more ? I just checked with Google AMP Validator but seems it is a valid AMP page.

    Best regards,

    Thread Starter fastwordpress

    (@fastwordpress)

    thank!
    I have already solved the problem myself.
    disabled optimization for amp pages.
    Litespeed cache ? Tuning ? url exclude ? /?amp$
    ?

    Plugin Support qtwrk

    (@qtwrk)

    Hi,

    Yes, there was an issue that lazy load image/iframe and google font async code will be inserted into AMP page, that should be addressed in future release.

    Best regards,

    This should be a more robust way to disable Litespeed on AMP pages:

    add_filter( 'litespeed_can_optm', function( $can ) {
    	if ( function_exists( 'is_amp_endpoint' ) && is_amp_endpoint() ) {
    		$can = false;
    	}
    	return $can;
    } );

    This is important because the ?amp in the URL is not always present or it can look different based on configuration.

    Important: This code requires that litespeed_can_optm run at or after the wp action in WordPress.

    • This reply was modified 5 years, 4 months ago by Weston Ruter.
    Akki

    (@luckyankit)

    This issue was resolved in latest version of Litespeed plugin. No extra code needed to add now.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Amp page problem validation’ is closed to new replies.