Idea Summary
URLs to Modal Dialog pages are in the form of
href="javascript:apex.navigation.dialog()"
With this changed behaviour in 23.1, this is actually a problem:
Consciously displaying "unsafe" HTML, such as script tags or javascript:
expressions, onclick
attributes, etc., is no longer possible as this content is stripped away.
Basically, the URL APEX generates is not in line with this principle.
We didn't notice this changed behaviour, because in upgrades, the type is changed to:
HTML (Unsafe) [Deprecated]
The idea is to do something about it. Either allow open dialog this way, or open dialog in another way (maybe through an action?).
Use Case
We have a lot of display only items that link to a modal page. E.g. an employee name that links to the employee modal dialog page:
<a href="' || apex_page.get_url(p_page => 27, p_items => 'P27_EMPNO', p_values => '7839') || '">KING</a>
The proposed solution in the 23.1 release notes is not practical:
- for Display Only Page Items in HTML format, use a Static Content Region
Preferred Solution (Optional)
I see several options:
Revert this change until APEX works consistently with the new HTML Sanitization policy.
“Un-deprecate” the option HTML (Unsafe) [Deprecated]
Change the URL to a modal dialog without using the javascript option.
Make an exception for opening modal pages.
Like CR/IR columns, add the attribute Escape special characters.