• Priority: High
  • Status: Closed
  • Theme: Alysum
  • Assigned To: Fred
  • Private: No
  • Open Date: 04.06.21, 14:30
  • Opened by: Rosita Paparelli
  • Closed by: Fred
  • Closed on: 15.06.21, 15:25
  • Reason: Closed
  • Comment: Glad to help!

Ticket #21629 - AMP cms pages doesn't Formbuilder PRO shortcodes or smarty hooks


the AMP module doesn’t parse Formbuilder PRO shortcodes nor smarty hooks shortcodes.

The page is the following: https://www.lapiantadelte.it/shop/mobile/page/15-contattaci.

As you can see at the top of the page, under the title “CONTATTACI” there is the shortcode of the form that has not been parsed.

Even If I use the smarty hook version of the shortcode - {hook h=’displayGform’ id=’1’} - the result is the same.

Can you please help?

Thank you.

Details to access my backoffice are in my profile.


Fred 04 Jun 2021, 14:36

Hi, Rosita.
Any third party module is not compatible with AMP by default. We have "AMPified" all prestashop pages and our own modules for the theme but we are not able to "AMPify" every third party module.

Rosita Paparelli 04 Jun 2021, 15:19

So how can I put a contact form on AMP cms page?

Fred 04 Jun 2021, 15:21

There is no such option.

Please read about AMP in details here: https://amp.dev/support/faq/overview/ and http://alysum5.promokit.eu/promokit/documentation/amp/index.html

Rosita Paparelli 04 Jun 2021, 16:02

I have been able to insert the form inside the cms page copying the hook {hook h='displayGform' id='1'} inside the file themes/child_alysum/templates/mobile/cms/page.tpl.

Now the form is visible but, unfortunately, when I click on submit inside the browser console I see the error: Uncaught (in promise) Error: Only XHR based (via action-xhr attribute) submissions are supported for POST requests

Can you please help me allow POST on AMP?


Fred 05 Jun 2021, 10:10

You are allowed to use POST on AMP. You need to use AMP form script, see an example here https://amp.dev/documentation/components/amp-form/