• Resolved joydipkar73

    (@joydipkar73)


    I am using BuddyPress and AMP plugin. But budypress pages are not working using AMP. So I disabled AMP in register page. But now the problem is that in internal profile page the uploads image etc are not working….
    I disabled AMP in members page as well, but that did not work…
    I think I should disable by page URL. How to achieve that?
    my members page id in buddypress is 14826.
    I used the below in function.php

    `add_filter( ‘amp_skip_post’, function( $skip, $post ) {
    if ( get_the_ID() == 14826) {
    $skip = true;
    }
    return $skip;
    }, 10, 2 );`

    but the URL is https://www.abc.com/members/stevan/profile/change-avatar/

    what to do?

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Support Milind More

    (@milindmore22)

    Hello @joydipkar73

    Thank you for the support topic, can you please try adding the following code snippet in your active themes functions.php or in a custom plugin

    add_action(
    	'wp',
    	function() {
    		if ( function_exists( 'is_buddypress' ) && is_buddypress() ) {
    			add_filter( 'amp_skip_post', '__return_true' );
    		}
    	}
    );

    Let me know if that helps!

    Thread Starter joydipkar73

    (@joydipkar73)

    no sir, this is not working

    Plugin Support Milind More

    (@milindmore22)

    Hello @joydipkar73

    ok, As I tested the code snippet on the demo site using AMP and BuddyPress it did work for me

    Following the demo BuddyPress pages don’t have an AMP version (?amp version)

    Members page

    Activity Page

    Profile Page

    PS: the site expires in 4 days

    Can you please share your site URL and site health information using this form so we can better understand your setup and provide you with a solution that can work for you.

    Thread Starter joydipkar73

    (@joydipkar73)

    I have submitted the form. please note that the image upload section in /members/<name>/profile/change-avatar/ URL is giving issues. there are the image upload facilities. that upload, crop, save portion is broken.

    Thread Starter joydipkar73

    (@joydipkar73)

    right now on my site, I have disabled AMP, so it is working fine for now. but it will reappear whenever I enable AMP.

    Plugin Support Milind More

    (@milindmore22)

    Hello @joydipkar73

    Thank you for the site health info, I am unable to replicate issues at my end, the code snippet I provided seems to be working for me

    I also created an account on your site to check but was unable to activate my account using the link in the email, if you can please activate my account so I can check the issue.

    To narrow down further, could you use the Health Check & Troubleshooting plugin and enable its troubleshooting mode. This mode disables active plugins and switches to a default theme safely since it only affects the experience of the logged-in user (admins).

    – Please enable the AMP plugin and let me know if the issue is present.
    – Enabling plugins and your theme one by one in this mode may help pinpoint if something else is involved.
    – Note you can disable troubleshooting mode from the plugins page.

    Thread Starter joydipkar73

    (@joydipkar73)

    I have just activated your account. Can you please also mention what issue was there while activating your email link?
    I have just enabled AMP, and please check in change-avatar page that the upload section is broken again.

    Plugin Support Milind More

    (@milindmore22)

    Hello @joydipkar73

    I don’t see AMP being used on your BuddyPress pages, I am also able to change my profile picture and cover image on my profile

    Please note I was not able to activate my account by clicking a link from an email or copy-pasting the link in the browser didn’t work, there was no error it just redirects to the homepage.

    Thread Starter joydipkar73

    (@joydipkar73)

    yes, I have disabled AMP on all templates.

    I have been able to figure out the activation problem the page slug was conflicting with another plugin page slug, therefore as it was not logged in, it redirected… it is resolved now.

    Plugin Support Milind More

    (@milindmore22)

    @joydipkar73

    Glad you are able to resolve the issue, I’ll mark this as resolved Open a new support topic if you face further issues, also feel free to leave a plugin review, we would love to hear your feedback.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘How to exclude AMP by page url?’ is closed to new replies.