#222 – Help with the proper hook for my IDX software

Posted in ‘weeblrAMP’
This is a public ticket. Everybody will be able to see its contents. Only enter usernames, passwords or any other sensitive information in the Private information field.
Monday, 01 June 2020 13:54 UTC
Andy K
 Hi. The programmer who wrote my IDX software has created a version that works on AMP pages and particularly weeblrAMP. But while it words perfectly with the official AMP plugin, pages don't display with WeeblrAMP. Here is the code he is using. Can you tell me how the hook needs to be changed to make this work? I am working with Rover and other companies beta testing software they have redesigned to work with weeblrAMP and you help would be appreciated. Here is my last communication with the programmer. Thanks in advance for your help:

I do have weeblrAMP support.  It must be the wrong hook.

# weeblrAMP is activated
# By WeeblrPress
# https://www.weeblrpress.com/accelerated-mobile-pages/weeblramp

if (class_exists('Weeblramp_Api') && Weeblramp_Api::isAMPRequest())
return true;
Monday, 01 June 2020 14:09 UTC

This looks good. This code will indeed detect if weeblrAMP is running or not. Then it all depends on:

- at which time they run the check, maybe they run too early, before weeblrAMP has decided whether this is an AMP request
- what they do with that information and how they ouput that "AMP compatible" content

I think it's best to just step through the code with a debugger and see whether this is called and run properly.

Best regards

Monday, 01 June 2020 18:36 UTC
Andy K
Thank you. I have passed this on and the programmer is testing with a debugger now.
This ticket is closed, therefore read-only. You can no longer reply to it. If you need to provide more information, please open a new ticket and mention this ticket's number.