KML - URL referencing icon png file not working?

I have a KML file with the following style:

	<Style id="AssetType">
		<BalloonStyle>
			<text><![CDATA[<table style='color:white'><tr><td><b>Type</b></td><td>$[Role]</td></tr><tr><td><b>Status</b></td><td>$[Status]</td></tr><tr><td><b>Country</b></td><td>$[Country]</td></tr></table><div style='position:absolute; right:0; bottom:0;'><a href="http://www.agi.com"><img style='height:24px;width:70px' src='agiLogo.svg'/></a></div>]]></text>
			<bgColor>#ff673005</bgColor>
			<textColor>#ffffffff</textColor>
		</BalloonStyle>
		<IconStyle>
			<Icon>
				<href>http://maps.google.com/mapfiles/kml/shapes/open-diamond.png</href>
			</Icon>
		</IconStyle>
	</Style>

The problem is the href never returns anything. When I run load the KML in Cesium SandCastle I get “Error loading image for billboard: Request has failed.” and I don’t understand why because I’m specifying the full URI to the file.
I pasted the URI into my browser directly and it displays just fine - Can anyone help?

Thanks!

@TScorpio

Welcome to the community :confetti_ball: :rocket: Can you please share some more information about your development setup? For instance, are you using Webpack to pack and import your files? If so, you must use a loader to host your files before accessing them using CesiumJS. Let me know if you have any additional questions or concerns. I am looking forward to learning more about your project. I struggled with a similar issue in a recent project :sweat_smile:

-Sam

1 Like