XF 2.3 Insert a banner on the forum header

AndreaMarucci

Well-known member
Hello, I'd like to know how can I put an image here in the forum header.

If it's possible I would like to make that image does appear based on time condition, eg. if the date is after 1st of january 2026, then the image is shown.

thanks

1758722538789.webp
 
Solution
What does the number 1767225600 mean? Is something related to 01/01/2026 in any way?
Yes, that's the UNIX timestamp. You can help with this: https://www.unixtimestamp.com/

Btw, I haven't tested this, but it should work.


will the image be responsive so it's resized gradually based on the screen resolution?
Sorry, use this code instead:
HTML:
<xf:if is="$xf.time > 1767225600">
    <img src="path/to/image.png" alt="Image" style="max-width:100%; height:auto;" />
</xf:if>
Thanks a lot! I'm trying.
Just a clarification.
What does the number 1767225600 mean? Is something related to 01/01/2026 in any way?

As far as you know, will the image be responsive so it's resized gradually based on the screen resolution?
 
What does the number 1767225600 mean? Is something related to 01/01/2026 in any way?
Yes, that's the UNIX timestamp. You can help with this: https://www.unixtimestamp.com/

Btw, I haven't tested this, but it should work.


will the image be responsive so it's resized gradually based on the screen resolution?
Sorry, use this code instead:
HTML:
<xf:if is="$xf.time > 1767225600">
    <img src="path/to/image.png" alt="Image" style="max-width:100%; height:auto;" />
</xf:if>
 
Solution
Back
Top Bottom