16.4.7.5.3 Generating Image URL with Secure Item
Generate checksum-protected image URLs by passing the image ID using the
tamper-resistant page item name to get_url using its
p_items and p_values parameters.
When using page 9005 to generate image URLs, the
get_url call
appears below in the modified Interactive Grid query. The p_items and
p_values parameters replace the previous
p_x01:select id,
title,
case
when image is not null
and dbms_lob.getlength(image) > 0
then apex_string.format('<img alt="%s" title="%s" src="%s">',
apex_escape.html_attribute(title),
apex_escape.html_attribute(title),
apex_page.get_url(
p_page => 9005,
p_items => 'P9005_ID',
p_values => ID))
end as image,
file_name,
posted,
posted_by,
updated
from eba_demo_emp_breakroom_photo_vTip:
If the image to download has a multi-column primary key, then pass multiple items and values in the
get_url call by separating values using commas:apex_page.get_url(
p_page => 9005,
p_items => 'P9005_ID1,P9005_ID2',
p_values => ID1||','||ID2)Parent topic: Weighing X01 Against a Secure Page Item