Dynamic picture with link on Wix Blog

Is there a way to set up a picture on like 50 blog posts that can be changed on all 50 at the same time. I want to put a picture with a link on my blog that links to a website or another page on my Wix website. I need to change the picture every few months as it is time sensitive -an advertisement for an event.

Sure, that’s easy (you don’t even need Wix Code for this).

Wix Blog is an App Market application. As such, the blog post page itself has a large element that takes most of the space of the page and includes the blog title, blog content, etc. You actually resize and move this blog box and position a picture or any other elements above, around or below this box. Just place the picture on the blog page and replace it every few months.

1 Like

Many Thanks!!
הרבה תודות!!

Hi Kevin,
Please note that if you add an image to the post page (named “single-post” in the pages list) - it will appear for all posts. If what you want is to have the image displayed only for some of the posts, you can do it using Wix Code by checking the URL (using wix-location ) which is unique per post and displaying the image only for the desired posts.

Hello Ohad,

Can you tell me where would you put this code to check the location? I am currently adding an image to a blog post that is linked to a dataset of images so each post page will have a different image depending on the post.

My problem is I have put the code in the post’s page’s onReady function but that is not getting called if I traverse from one page to another.

Any help will be appreciated.