Image()

Returns an img tag in which the src attribute is the path to an image from your Portfolio. The img tag includes the title and alt information for the selected image, a border attribute set to 0, and a thid attribute that contains the ID of the image in the Portfolio.

The Image() function has two parameters:

  • imageExternalKey (string): Required. The external key of an image in your Portfolio.
  • defaultImageExternalKey (string): The external key of a fallback image in your Portfolio. The function uses this image if it can’t find the image that you specified in the imageExternalKey parameter.

To use this function, pass it the external ID of an image in your Portfolio. You can optionally specify a default image to use if the function is unable to find the first image.

If the function finds the image that you specified in the first parameter, it returns an <img> tag that refers to that image.

If the function doesn’t find the specified image, it returns an <img> tag that refers to the image that you specified in the second parameter.