Jump to content

Banner type: PHP


Tim Vereecke

Recommended Posts

Hi,

Is there a banner type which supports executing PHP to render the banner HTML dynamically?

Current state

I currently have an HTML banner which populates dynamic data like below (4 dynamically picked products, with up to date pricing).

The JS code to fetch and display the data runs client side. Although it works like a charm it does involve multiple requests.

1236983-10000-53-1440.png?impolicy=defau

Question for future state

I would like to execute this logic server side and have Revive return the server side rendered HTML by executing PHP (read from database).

Is it possible? And what is the best approach to do that? 

I tried looking for an existing plugin and or forum post discussing this; but failed to find it?

 

Thank you for your guidance!

Tim

Link to comment
Share on other sites

  • 2 weeks later...

I was thinking of something very similar*, but have not yet found the time to try it out. One possibility would be using an Iframe. But of course, this also adds another request.

* My use case is for WordPress: We cache the rendered pages, but I would like to include a block similar to yours to show featured or most-read posts (I know there are plugins for this, but most of them do not work properly with caching. Delivering these recommended blog posts via Revive would solve several problems in our setup).

 

PS: Funny to meet you here, I have been following you on Twitter for some time, due to my interest in web performance

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...