I'm trying to embed a jpeg into a simple XML dashboard with HTML. It looks like this:
<dashboard> <label></label> <description/> <row> <html> <img src="picture.jpg"/> </html> </row> </dashboard>
I've obviously excised the page content just to show how I'm trying to include the picture.
The file "picture.jpg" is living in
All I'm seeing is a big old broken image link. Any thoughts?
In order to display a static image on a dashboard I created the images directory on the path below -
The dashboard with the embedded images have the following source:
See if html panels work
<html> <h1>HTML Panel Example</h1> <p>The HTML panel displays inline HTML.</p> <pre><img src="/static/app/search/images/pretty1.jpg"/></pre> </html> </row> <row> <html> <h1>HTML Panel Example</h1> <p>The HTML panel displays inline HTML.</p> <pre><img src="/static/app/search/images/pretty2.jpg"/></pre> </html> </row>
Was very useful to install the Dashboard 6.x examples app -
Wow. I got it to work, and I don't know why.
In my code, I have:
But, my directory structure is:
Why does this work? Am I only one that thinks this is weird?
No wonder this has been kicking my butt for so long. I stopped trying to understand it, and went with Arkonner's pathing, then removed all the jpgs I had in multiple directories, until I found that combination above.
So, my new questions is: WTF?
Hi, this is driving me crazy. I tried the same as above, but with no success.
Its every time the broken image, but not the picture.
Who has the magic to solve this, or to explain how it will work - I can't find THE documentation...?
We found the following solution:
Uploading Picture to physical path on searchhead:
We used the following line in Panel-Source:
img src="https://hostname:8000/en-US/static/app/$myappname$/picture.jpg" alt="picture"
Next Problem is to replace the picture with a new one.
It seens that we need to restart the splunk or webserver deamon.
My way is to delete the picture und creating a new with a new name.
I hope this bad things will be fixed in later versions, because I want to use splunk, not to administrate it.
Just double check the name of the image. Make sure it is same as it shows on the server.
Even image extension case should be the same.
i.e. if image name is "abc.JPG", then you should mention "/static/app/urapp/abc.JPG" only, not "/static/app/urapp/abc.jpg".
Otherwise it will throw 404 error.
Sometimes we ignore these small things but they will make you go crazy 🙂