Forum Discussion
Robert Ohare
May 16, 2019Copper Contributor
How would I add an image link to a page with the page title as the image name Classic Sharepoint
Hello All, I wanted to add an image that is dynamic to a DocSetHomepage. I want the Image that is displayed in the webpart to display to have the following format /teams/Base/Admin/Photos/(...
Thomas Berman
Jun 12, 2019Iron Contributor
You could add a Content Editor Web Part (CEWP) to the doc set home page.
In that web part, grab add a root element, then have a <script> where you grab _spPageContextInfo to get your title, then build your <img src='/teams/Base/Admin/Photos/' + title + '.png'> from there and inject it into your root element.