Layouts Product. include json. for divi

fricardomolina

New member
XNullUser
Joined
Jul 7, 2022
Messages
6
Reaction score
3
Points
3
NullCash
22
Theme Free Product divi layout json
  • Use a templateengine to display the data from an JSON-Feed.
  • Define the url of the JSON-Feed, a template for it and other options like number of displayed items, cachetime etc..
  • Cacher with new Option: If a http-API request fails, you can use the maybe cached JSON. Set the radio-button in the plugins settings: what API-problem should be handled how (either a non valid API-http-response or a non JSON-API-response – or both). By default for backwards-compatibility this is switched off. Recommendation: Switch on the plugins-cacher (e. g. some minutes) and select the radiobutton for «If the API-http-answercode is not 200 OR sends invalid JSON: try to use cached JSON» in the plugins options.
  • The templateengine inserts the JSON-data in the template.
  • You can either use this as wordpress-shortcode inside a page – whereby some extras like urlencoding can be invoked.
  • Or use the Gutenberg Mode: Then you don’t have the hassle to put an shortcode together, test it and change it. With a Gutenberg-Block you can test it in realtime and create a shortcode (if you want to stay with shortcodes).
 

Attachments

  • product.zip
    764.8 KB · Views: 0
Top