MashZone NextGen 10.2 | Appendix | Legacy Presto components | Mashables and Mashups | Views for Mashups and Mashables | Built-in MashZone NextGen Views | Template View | Use Images in Template Code
 
Use Images in Template Code
To use images in a custom view or template, they must be hosted outside of MashZone NextGen at a fully-qualified URL or a MashZone NextGen administrator must upload the image file to MashZone NextGen. Image files may be in any commonly-used format for web pages, such as GIF, PNG or JPEG.
You can add images to a custom view or template using CSS styles or using an <img> tag in the view or template HTML code. This is an example using CSS and an external image:
...
<div style="height: 180px; width: 250px;
background:url('http://myOrg.com/images/logo.png"></div>
...
With images that have been uploaded to MashZone NextGen you simply use the MashZone NextGen URL. The full path for this URL is defined when the resource is uploaded, but is generally in the form http:app-server:port/mashzone/files/filename. This example uses an <img> tag and a MashZone NextGen URL:
...
<img src="http://localhost:8080/mashzone/files/myHeader.png"/>
...

Copyright © 2013-2018 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Innovation Release