Oracle html-db or  appliction express java script intqegration

hi , i'm very new at this and i come from microsoft world , so i know javascript very well , but some how i cant find the to integrate it into a simple page button or item .
can anyone please show me an exsample where do i write the javascript to corospand with an itemin a page?
thank's ahead
iris hadar
[email protected]

Hello Iris,
The following will give you the basic stuff you need - http://download-uk.oracle.com/docs/cd/B31036_01/doc/appdev.22/b28839/javascript.htm#CIHEBFFC
Carl's examples, in the specific page he pointed, are based on some built in JavaScript functions, that are available to you on every page. They are all defined in a file called htmldb_html_elements.js.
If you are mastering JavaScript, you'll find this Carl's page very interesting - http://htmldb.oracle.com/pls/otn/f?p=11933:63 . This is an intro to the more advanced capabilities ApEx can present, using AJAX. There are lots of AJAX examples on this forum.
Hope this helps,
Arie.

Similar Messages

  • Calling a java script function while page loads in ebiz

    Hi OAF gurus,
    I have a requirement of Calling a java script function at each OAF page renders or Loads.
    I.e. when any OAF page loads or render in Oracle e-biz i have a java script function which needs to be called Is there any way to implement the above mentioned requirement.
    Many thanks in advance..
    Sourav

    Hi!
    From OAF classes java doc:
    oracle.apps.fnd.framework.webui.OAPageBean
    A class for processing and rendering HTML pages, designed to be invoked from either a JSP page or a servlet.
    Allows you to:
    Validate a user's session and redirect to a login page.
    Set the servlet Response content type to the correct character set as defined by the ICX_CLIENT_IANA_ENCODING profile. (The character set should NOT be set in the JSP page ContentType declaration.)
    Parse a HTTP Request and initialize BC4J application modules and view objects. (For HTML post, apply the content of the submitted form parameters to view objects.)
    Render a HTML page header and body
    It has 2 metods:
    public void renderDocument()
    Renders the HTML document. This is the most common API invoked by JSPs or servlets, and is used to render both the HTML header and body.
    renderBody
    public void renderBody()
    Renders the HTML body only.
    I think you can decompile this class or get the source from oracle and add your javascript code into this method.
    When OA page rendered, your code would be added to avery page, i think
    But it's some kind of hack or something ;-)

  • How to create two level dynamic list using JSP , Java Script and Oracle

    I am new in JSP. And i am facing problem in creating two level dynamic list using JSP ,Java Script where the listdata will come from Oracle 10g express edition database. Is there any easy way in JSP that is available on in ASP.NET.
    Plz response with details.

    1) Learn JDBC API [http://java.sun.com/docs/books/tutorial/jdbc/index.html].
    2) Create DAO class which contains JDBC code and do all SQL queries and returns or takes ID's or DTO objects.
    3) Learn Servlet API [http://java.sun.com/javaee/5/docs/tutorial/doc/].
    4) Create Servlet class which calls the DAO class, gets the list of DTO's as result, puts it as a request attribute and forwards the request to a JSP page.
    5) Learn JSP and JSTL [http://java.sun.com/javaee/5/docs/tutorial/doc/]. Also learn HTML if you even don't know it.
    6) Create JSP page which uses the JSTL c:forEach tag to access the list of DTO's and iterate over it and prints a HTML list out.
    You don't need Javascript for this.

  • How to call userdefined java script function in Oracle Forms 11g.

    Hi,
    I Created a java script contain a function, that will open and close the browser for some URL.
    CODE:-(webclose.jp)
    *function manageWindows() {*
    var windows = [], i = 0;
    var url =  "htttp://oracle:64578/xmlpserver/login.jsp?Go&id=admin&passwd=admini";
    *if (url.length) {*
    *windows[i] = window.open(url, ' tabWindow_'+i);*
    i++;
    *winows[i-1].close();*
    *delete windows[i-1];*
    return false;
    *}* Then i placed the javascript file in path <middleware_home>\user_projects\domains\<domain>\servers\WLS_FORMS\_WL_user\formsapp_11.1.1\e18uoi\war\
    After that i called the javascript function in to forms as
    WEB.JAVASCRIPT_EVAL_EXPR('webclose.manageWindows();');
    When running the form it showing error
    FRM-92190: JavaScript is unable to evaluate expression.
    If anybody knows pls help me.

    Always post code snippets in &#123;code&#125; tags as explained in the FAQ.
    I Created a java script contain a function, that will open and close the browser for some URL.
    CODE:-(webclose.jp)
    function manageWindows() {
    var windows = [], i = 0;
    var url = "htttp://oracle:64578/xmlpserver/login.jsp?Go&id=admin&passwd=admini";
    if (url.length) {
    windows = window.open(url, ' tabWindow_'+i);
    i++;
    winows[i-1].close();
    delete windows[i-1];
    return false;
    } Then i placed the javascript file in path <middleware_home>\user_projects\domains\<domain>\servers\WLS_FORMS\_WL_user\formsapp_11.1.1\e18uoi\war\
    After that i called the javascript function in to forms as
    WEB.JAVASCRIPT_EVAL_EXPR('webclose.manageWindows();');
    When running the form it showing error
    FRM-92190: JavaScript is unable to evaluate expression.
    If anybody knows pls help me.>
    This error has nothing to do with Forms, it is an JavaScript error.
    Most likely cause is this line
    if (url.length) {url.length returns a Whole number and so the conditions would be
    if (url.length > 0) {Or
    if (url) {  // not null checkCheers,

  • How to load a java script in oracle database

    Is it possible to load d java script in Oracle database. while the object type is
    java resource ..

    RENUJP wrote:
    I meant to load a javascript to oracle database not to oracle appliocation.
    like loadjava....
    I can load a javascript to oracle database.. but i can't call it...Please re-read the comments above, especially the part about this not being a javascript nor oracle forum. Exactly what part about this information don't you understand?

  • Page failure when attempting to save java script in html header

    Currently there is java script code for a function that is seeded in the html header of a forms page by apex when the form is generated. This code is for the chicken test for the DELETE button.
    The function works as designed, but if I try to "APPLY CHANGES" to the the page definition I get the The page cannot be displayed "Cannot find server or DNS Error". "the url is http://nldg-3.appl.devjones.com:7777/pls/apex/wwv_flow.accept" If I remove the script coding from the HTML header the page will save just fine, but of course no more java script.
    I need to add a java script function to the page and I am unable to do so at this time because of this issue. I can reproduce this error on any of the sample apps that I have loaded into apex.
    the Apache error log contains:
    [Fri Feb 13 06:11:06 2009] [error] [client 172.16.85.122] [ecid: 1234527066:192.168.211.127:31922:0:17188,0] mod_plsql: /pls/apex/wwv_flow.accept HTTP-500 Error Reading Data from Client!!
    The Apache access gets:
    172.16.85.122 - APEX_PUBLIC_USER [13/Feb/2009:06:23:47 -0600] "POST /pls/apex/wwv_flow.accept HTTP/1.1" 500 653
    Apex is version 3.1.2.00.02 and uses on iAS on a Linux server. The Database is 10g. The browser is IE 6.0.2900.2180.
    I have been developing for about 3 months in Apex and this is the first issue of this kind that I have run into. Any help will be greatly appreciated as I have no clue at this time.

    Luis,
    All the forms are created by Apex with a default function in the html header for a delete chicken test as follows:
    <scrpt language="JavaScript" type="text/javascript">
    <!--
    htmldb_delete_message='"DELETE_CONFIRM_MSG"';
    //-->
    Even though the function is already a part of the page, if I try to save it, it will fail. I will look into the "black list" a little deeper. I have asked around abit as I also had suspected that, but so far all the answers were that it should not be a problem. If I take out the "SCRIPT" word I can get the page to save, but of course the code is worthless at that point.
    Keith

  • How to populate a table in the html page from the java script

    Hi all,
    I have doubt in populating a table in the html page. my application is as follows
    I have a html page in which i have a combo box and a table following the combo box.
    i have to populate the table depending on the item selected in the combo box.
    for this i am using javascript to get the value of combo box onClick
    then i have to call some function thru jsp to get the data and then i have to populate the table with thst into from java script
    how can i do this, i.e populating html table from java script
    Thanks in advance
    satya

    Hi Mihai,
    You can populate data in DO_INIT_CONTEXT method of ur impl class in your Z component.
    data:
    lv_struct_ref type ref to YOUR_STRUCTURE,
    lv_value_node type ref to cl_bsp_wd_value_node,
    lv_bo_coll type ref to if_bol_bo_col.
    Data: current type ref to if_bol_bo_property_access.
    data: dref type ref to data.
    data: lv_guid_h type crmt_object_guid.
    data: lt_attr type table of YOUR_STRUCTURE.
    data: ls_attr type YOUR_STRUCTURE.
    data: lr_entity type ref to cl_crm_bol_entity.
    create object lv_bo_coll type cl_crm_bol_bo_col.
    lt_attr is ur internal table.
    Loop at lt_attr into ls_attr.
      create data lv_struct_ref.
      create object lv_value_node
           exporting
                iv_data_ref = lv_struct_ref.
    call method lv_value_node->if_bol_bo_property_access~set_property
    exporting
    iv_attr_name = 'YOURFIELDNAME1'
    iv_value = ls_attr-firstname.
    call method lv_value_node->if_bol_bo_property_access~set_property
    exporting
    iv_attr_name = ' YOURFIELDNAME2'
    iv_value = ls_attr-lastname.
    lv_bo_coll->add( lv_value_node ).
    typed_context->YOURCONTEXTNODE->set_collection( lv_bo_coll ).
    endloop.
    Regards,
    Raghu

  • Need to compare html text area values by using java script

    I have one html text area in my JSP file. when i click on that text area, a pop-up will come, in that pop-up i have list of items. So after selecting a item from that pop-up list, need to click okay. so that text area will update with the selected value.
    In this case, i need to compare the first text area value and updated text area value. How can i do that in Java Script.

    I suggest you look for a Javascript forum to ask questions about Javascript. This is a Java forum.

  • I can not get Firefox to play music backgrounds on pages in browsers it works in IE and other browsers but not firefox, what HTML or Jave script do I need too use to make them work?

    I'm having a problem with firefox playing background music on some sites, it works with IE and other browsers but not with fire fox, what html or java script do I need to add to the pages so that they play the music?
    I develop my pages in Front Page and I know that the music only works in IE, so if someone can tell me how to correct this problem as it is important as I use fire fox as my main browser.
    I thank you in advance

    If a website uses BGSOUND then it will only work in IE.
    BGSOUND is not compatible with other browsers like Firefox.
    * http://kb.mozillazine.org/Background_music_does_not_play

  • How to use Java Script in Oracle Forms 10g

    Hello,
    Appreciate if anyone could help me using Java Script in Oracle Forms 10g?
    Thanks
    GM

    Thank you for your reply. I was reading on the metalink that we could use the to call the java script from oracle Forms 10g (Doc ID 265863.1)
    Example:
    WEB.SHOW_DOCUMENT ('javascript:void(window.open("http://www.oracle.com","","location=no,toolbar=no,menubar=no,status=no,"));self.close()','_blank');
    I tried it but it did not open the any window as it claims. Am I missing anything? Is there any IE related setting which I need to modify for the above to work?
    Regards
    GM

  • Oracle apex popup using java script in tabular form select list(Am new to apex help me out... )

    Hi ...
      i have a tabular form
      have two columns in that form, kept as a select list by selecting that 1st select list data the related datas has to be popup after selecting that it has to be displayed in the  2nd column by using
    java script
    eg:
    1st column empno-----by selecting the empno the related empname has to be popup
                     dept no....by selecting the deptno the related deptname has to be popup 
    thanks in advance,
    kishore

    This is a very common question, see
    https://forums.oracle.com/thread/2359498

  • Business Objects Dashboard External HTML/JAVA Script Link - User Authentication Depolyment Q

    <p>Hello,</p><p>I have a rather unstructured problem here and am relatively new to Business Objects Enterprise. </p><p>We have users who are authenticated through Business Objects. The login sets their access levels and permissions. In addition to the BO reports, we would also like to link through BO Dashboard a JAVA Script webpage.</p><p>The JAVA Script and Business Object software sits on the same webserver.</p><p><strong>The problem is that through BO Dashboard and also an external URL link we can only pass a static link (i.e. /some directory/some doc.html) and not a dynamic userid with the URL, which changes based on the user (i.e. /some directory/some doc.jsp?UID=user1).</strong></p><p>The solution might be to insert a Business Object API call that can determine the user who is currently logged in? Or, if there is some way around the static html link through Business Objects Dashboard?</p><p>Any ideas or thoughts would be deeply appreciated.</p><p>Thanks,</p><p>Joe</p>

    Are you setting Business Objects up as an external application?
    If so, what parameters are you using to set it up?
    Based on the fact that you're seeing the basic auth dialog, you probably need to specify
    that it's using basic auth -- not GET.

  • How to use HTML and Java Script files in Portal

    Hi,
    I am trying to access a web application using iViews. My application contains JSP,HTML,Servlets,JS(java script), image files. I am using JSPDynPro to access the JSP files and I am putting servlets in the private/lib folder of the PORTAL-INF dir of Portal project. Now my problem is almost all the JSP files uses the HTML files, JS files and image files. Where can put these files in the portal project dir structure to give access to the JSP files when i am creating a iView for the JSPDynPro componenets in the irj.
    thanks,
    Ashok

    Hi,
    JSPDynpage is the controller, one JSPDynpage can call more than one jsp file according to the coding. Through the JSPDynpage's setJspName() function only you can display a jsp page.
    EX:
    public void doProcessBeforeOutput() throws PageException {
      this.setJspName("logon.jsp");
    if you put the JSPDynpage in the src.core then the JSPDynpage can be accessed only by this application.
    if you put the JSPDynpage in the src.api then other applications can access this component.
    You can put the jsp pages in the pagelet folder.
    xml file
    =========
    <?xml version="1.0" encoding="utf-8"?>
    <application>
      <application-config>
        <property name="SharingReference" value="com.sap.portal.htmlb"/>
      </application-config>
      <components>
        <component name="jspdynpage name">
          <component-config>
            <property name="ClassName" value="package name.jspdynpagename"/>
          </component-config>
          <component-profile>
            <property name="tagLib" value="/SERVICE/htmlb/taglib/htmlb.tld"/>
          </component-profile>
        </component>
      </components>
      <services/>
    </application>
    REWARD USEFUL ANSWERS

  • Adobe Java Script Expressions

    Question #1    I have a check box field and two data fields containing only letters no numbers in an Adobe Acrobat Form. I would like to have a java script expression that if the Check box 1 field is checked, the contents of Data Field 1 will be automatically entered into Data Field 2 .
    Please provide script and below are the 3 fields.
    Check box 1 field: Checked
    Data Field 1
    Data Field 2
    Question #2    I have a field labeled Full Address that I am trying to get the following fields to populate from. The problem in my expression is when there is no Suite then there is an extra comma still showing.
    Please provide script.
    Sample of my script below.
    event.value = this.getField("Merchant_Addr1").value.concat( ", ", this.getField("Merchant_Addr2").value) + ", " + this.getField("Merchant_City").value + ", " + this.getField("Merchant_State").value + "  " + this.getField(" Merchant_Zip").value;
    This is what displays if no Suite is in Address (Two commas after the word Drive: 23175 La King Drive, , Irvine, CA  92656
    Data Field Street Address
    Data Field Suite (If empty then don't show comma)
    Data Field City
    Data Field State
    Data Field Zip

    For question number 2, I would use a reusable document level function to combine 3 fields a time and adjust for null field values.
    // Concatenate 3 strings with separators where needed
    function fillin(s1, s2, s3, sep) {
    Purpose: concatenate up to 3 strings with an optional separator
    inputs:
    s1: required input string text or empty string
    s2: required input string text or empty string
    s3: required input string text or empty string
    sep: optional separator sting
    returns:
    sResult concatenated string
    // variable to determine how to concatenate the strings
      var test = 0; // all strings null
      var sResult; // re slut string to return
    // force any number string to a character string for input variables
      s1 = s1.toString();
      s2 = s2.toString();
      s3 = s3.toString();
      if(sep.toString() == undefined) sep = ''; // if sep is undefined force to null
    assign a binary value for each string present 
    so the computed value of the strings will indicate which strings are present
    when converted to a binary value
      if (s1 != "") test += 1; // string 1 present add binary value: 001
      if (s2 != "") test += 2; // string 2 present add binary value: 010
      if (s3 != "") test += 4; // string 3 present add binary value: 100
      /* return appropriate string combination based on
      calculated test value as a binary value
      switch (test.toString(2)) {
      case "0": // no non-empty strings passed - binary 0
         sResult = "";
      break;
      case "1": // only string 1 present - binary 1
         sResult = s1;  
      break;
      case "10": // only string 2 present - binary 10
         sResult = s2;  
      break;
      case "11": // string 1 and 2 present - binary 10 + 1
         sResult = s1 + sep + s2; 
      break;
      case "100": // only string 3 present - binary 100
         sResult = s3;
      break;
      case "101": // string 1 and 3 - binary 100 + 001
         sResult = s1 + sep + s3; 
      break;
      case "110": // string 2 and 3 - binary 100 + 010
         sResult = s2 + sep + s3; 
      break;
      case "111": // all 3 strings  - binary 100 + 010 + 001
         sResult = s1 + sep + s2 + sep + s3; 
      break;
      default: // any missed combinations
         sResult = "";
      break;
    return sResult;
    var Addr1 = this.getField("Merchant_Addr1").valueAsString;
    var Addr2 = this.getField("Merchant_Addr2").valueAsString;
    var City = this.getField("Merchant_City").valueAsString; 
    var State = this.getField("Merchant_State").valueAsString;
    var Zip = this.getField(" Merchant_Zip").valueAsString;
    var s = fillin(Addr1, Addr2, City, ", ");
    var s = fillin(s, State, "", ", ");
    event.value = fillin(s, Zip, "", "  ");
    Or the custom calculation script could be reduced to:
    // custom calculation script;
    var Addr1 = this.getField("Merchant_Addr1").valueAsString;
    var Addr2 = this.getField("Merchant_Addr2").valueAsString;
    var City = this.getField("Merchant_City").valueAsString;
    var State = this.getField("Merchant_State").valueAsString;
    var Zip = this.getField(" Merchant_Zip").valueAsString;
    event.value = fillin(fillin(Addr1, Addr2, fillin(City, State,"", ", "), "", ", "), Zip, "", "  ");
    Do not forget the fillin function.

  • Need help with Java script calling an html page

    Hello -
    I have a bunch of web pages, that call a java script called "header.js". The "header.js" puts a header on the top of each web page. In the Java script, I have a gif (picture) that displays a logo and if you click on it, it will send to you a different website.
    I'd like to replace this gif with an actual web page. So, the "header" would actually be a web page and not some gif.
    Below is a snippet of the code and I'd like to replace the highlighted section with a web page called "header.html". I don't even know if this is possible.
    Can anyone tell me what I need to do? I know pretty much nothing about Javascripting so please be as detailed as you can. Thanks!
    /* Common header across all pages... */
    document.write('            <div id="header" class="clearfix">');
    document.write('                            <div id="left" class="float_left">');
    document.write('                                            <div id="logo"><a href="http://www.xyz.com/" onclick="window.open(this.href);return false;" onkeypress="window.open(this.href);return false;" target=_blank><img src="/images/xyz.gif" width="105" height="75" alt="" border="0" /></a></div>');
    document.write('                                            <div id="mainNav" class="clearfix"> ');
    document.write('                                                             <ul>');
    //document.write('                                                                         <li id="nav_controls"><a href="controls.html">Controls</a></li>');
    document.write('                                                                              <li id="nav_motion"><a href="motion.html">Motion</a></li>');
    document.write('                                                                              <li id="nav_sensor"><a href="sensor.html">Sensor</a></li>');
    document.write('                                                                              <li id="nav_encoder"><a href="encoder.html">Encoder</a></li>');
    document.write('                                                                              <li id="nav_system"><a href="system.html">System</a></li>');
    //document.write('<!--                                                                  <li id="nav_logs"><a href="#">Logs</a></li> -->');
    document.write('                                                             </ul>');
    document.write('                                            </div>');
    document.write('                            </div>');
    document.write('                            <div id="right" class="float_left">');
    document.write('                                            <div id="controls">');

    Well, the problem with this is that I'm not an expert on SSI and I really know nothing about javascripting...so I'm afraid of breaking the whole web site and also having to modify all the web pages that call this header.
    I'll have to read up on server side include...cause I don't know much about it.
    If I could do what I want with this "header.js", it would be a lot easier.

Maybe you are looking for

  • F-53, Simulate time getting message "Correct the marked line items"

    Hi All, While posting the outgoing payment (F-53),  at time of simulate I'm getting the message " correct the marked line items" & missing the vendor side line item but showing for enter amont( bank acccount line items) on screen. when I trying to do

  • Webi export to excel having issues.

    Hi, I have a webi report which generates 62 mb excel file when exported to excel. It can be saved to excel without any error but when we open the excel report it shows the error that there are some damage done to report and excel is trying to recover

  • Problem with input data format - not "only" XML

    Hi Experts, I have problem with input data format. I get some data from JMS ( MQSeries) , but input format is not clear XML.  This is some like flat file with content of XMLu2026. Example: 0000084202008-11-0511:37<?xml version="1.0" encoding="UTF-8"?

  • New firmware for the N97?

    Anybody know when a new firmware will be released for the N97? Thanks. Solved! Go to Solution.

  • Had my ipod 3 yrs and now it won't charge or play anymore

    I have had my ipod nano around 3 years.  Use it when I run and on my motorcycle, so I have used it maybe around 100 times in the last three years.  I plugged it in one day and it will not take a charge and will not play.  I know my plugin connection