You are viewing the Resources for the older version of JourneyApps (V3). JourneyApps V4 is the new default for all new apps since July 1, 2016.

All View Components → display-image

Select a view component to see details on how it works:

display-image

A component that simply display a static image (for example, a company's logo).

Please Note: This functionality has been available since version 3.16.0 of the JourneyApps Container on Android, and since version 1.7.1 of the JourneyApps Container on iOS. If you have trouble while trying to use this functionality, please ensure that you've updated to the latest versions of the JourneyApps Container on either Android or iOS.

Notes on Image Display

  • Only images in PNG format are supported.
  • The imaged is scaled to take up the entire column width, preserving aspect ratio.
  • The image is displayed without any borders.
  • PNG transparency is preserved, showing the white background behind the image.
  • If the image specified in src="" (see below) is not found, the component is hidden completely (takes up no space).

Example

Code in View XML:

Appearance on mobile device:

Configuration

Option Required? Details
src required Path to the image file (the file must uploaded using the Icons & HTML tab in the JourneyApps Editor). Only images in PNG format are supported

The value provided can be a Format String if you need to dynamically specify the path of the image file.
show-if optional Controls whether the component is hidden or shown. The argument specified to show-if can either be a literal boolean value (true or false), or it can specify a variable, parameter or attribute that can be a string, number, object, etc. that evaluates to false or evaluates to true (see the section Show/Hide Components Dynamically for full details).

hide-if optional The opposite of show-if (see above).