如何从Javascript访问Oracle Apex变量? [英] How to access Oracle Apex variables from Javascript?

查看:269
本文介绍了如何从Javascript访问Oracle Apex变量?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Oracle APEX但不确定如何从外部javascript文件访问以下变量,该文件可能位于应用服务器上或存储在共享组件 - >静态文件中。

I'm using Oracle APEX but am unsure how to access the following variables from an external javascript file that may be located on the app server or stored in Shared Components -> Static Files.

:APP_ID
:APP_PAGE_ID
:APP_SESSION

如何从javascript(存储为静态文件)中引用上述每个值?

How can I reference the values for each of the above from javascript (stored as a Static File)?

推荐答案

这些值在页面上呈现为隐藏的项目,如下所示:

These values get rendered on the page as hidden items like this:

<input type="hidden" name="p_flow_id" value="4000" id="pFlowId" />
<input type="hidden" name="p_flow_step_id" value="4150" id="pFlowStepId" />
<input type="hidden" name="p_instance" value="6528421540413702" id="pInstance" />

因此您可以将它们引用为:

so you can reference them as:

$v('pFlowId') // APP_ID
$v('pFlowStepId') // APP_PAGE_ID
$v('pInstance') // SESSION

遗憾的是,它们与会话状态的名称不同!

It's a pity they aren't named the same as the session state!

这篇关于如何从Javascript访问Oracle Apex变量?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆